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

Allow deferring plugin execution so loaders have time to generate files #40

Closed
Obi-Dann opened this issue Aug 23, 2017 · 3 comments
Closed

Comments

@Obi-Dann
Copy link
Contributor

Obi-Dann commented Aug 23, 2017

Hi,

We recently started using https://github.com/Jimdo/typings-for-css-modules-loader. It creates d.ts files for css-modules providing us with type checking and intellisense on css class names.
The problem is that the d.ts files are typically generated after fork-ts-checker-webpack-plugin is started. It means, the plugin either throws an error that a file is missing or checks an old version of d.ts file.

I suggest to add an async plugin hook fork-ts-checker-service-before-start so I can defer fork-ts-checker-webpack-plugin start up from another plugin.
If it sounds alright, I can create a PR implementing it.

I guess another option would be to add a flag startAfterFinishModules or startAfterCompile so the plugin will start type checking on compilation finish-modules or compiler after-compile

@Obi-Dann Obi-Dann changed the title Defer plugin execution to allow loaders to generate files Allow to defer plugin execution to allow loaders to generate files Aug 23, 2017
@Obi-Dann Obi-Dann changed the title Allow to defer plugin execution to allow loaders to generate files Allow deferring plugin execution so loaders have time to generate files Aug 23, 2017
@piotr-oles
Copy link
Collaborator

Hi :)
The first option sounds more elastic for me, so please implement this one if it's not a problem.
PR's are always welcome :)

@Obi-Dann
Copy link
Contributor Author

Awesome, thanks, I've created a PR #44

@piotr-oles
Copy link
Collaborator

Merged! I will release it as 0.2.8 :)

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