Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Emitted files #2

Open
strarsis opened this issue Feb 18, 2021 · 1 comment
Open

Emitted files #2

strarsis opened this issue Feb 18, 2021 · 1 comment

Comments

@strarsis
Copy link

strarsis commented Feb 18, 2021

So I read through the comments in your source code. Webpack plugins emit files which can then further be handled.
Here is an example for placing the generated font files into a separate directory:

    new FontfacegenWebpackPlugin({
      tasks: [
        'resources/fonts/my-font.ttf',
      ],
    }),
    new CopyPlugin({
      patterns: [
        { from: '**/myfont*', to: 'public/fonts' },
      ],
    }),

However, the approach above has two drawbacks: First drawback: The glob must be tailored to the input fonts. Second drawback: The copy plugin creates a copy, so the files are still written to their original destination (output root).

@strarsis strarsis changed the title How to use/reference the output Emitted files Feb 18, 2021
@daniel-araujo
Copy link
Owner

Thank you for providing a neat workaround. I might include this in the README file until I can come up with a proper solution.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants