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

5.0.1: The "files" glob patterns is not working properly #450

Closed
liaoliaots opened this issue Jun 17, 2020 · 2 comments
Closed

5.0.1: The "files" glob patterns is not working properly #450

liaoliaots opened this issue Jun 17, 2020 · 2 comments
Labels

Comments

@liaoliaots
Copy link

liaoliaots commented Jun 17, 2020

Current behavior

For version4, I use "reportFiles" to ignore some unuseful “.ts” or ".tsx" files, this plugin works normaly.

reportFiles: ['./src/**/*.{ts,tsx}', '!src/ts/**/*.{ts,tsx}']

For version5, I use "eslint" -> "files" to ignore same files.

For example:

files: ['./src/**/*.{ts,tsx}', '!src/ts/**/*.{ts,tsx}']

But this plugin throws an error:

Error: No files matching 'D:/GitHub/code-twitter/!src/ts/**/*.{ts,tsx}' were found.

It seems like a path, not glob patterns.
Is this a normal behavior?

Sorry for my bad english.

Expected behavior

The "files" option should ignore files properly.

Steps to reproduce the issue

Issue reproduction repository

Environment

  • fork-ts-checker-webpack-plugin: 5.0.1
  • typescript: 3.9.5
  • eslint: 7.2.0
  • webpack: 4.43.0
  • os: Windows 10 1909
@liaoliaots liaoliaots added the bug label Jun 17, 2020
@piotr-oles
Copy link
Collaborator

The files parameter works inclusive - not exclusive. If some of the patterns don't resolve to existing files, eslint will throw an error (it behaves the same as eslint command).

If you want to mimic the behavior of reportFiles, you can use issue option:

  issue: {
    exclude: [
      {
        origin: 'eslint',
        file: 'src/ts/**/*.{ts,tsx}'
      }
    ]
  }

@liaoliaots
Copy link
Author

It works now, thanks.

andriijas pushed a commit to facebook/create-react-app that referenced this issue May 28, 2021
* Revert "Revert "Update postcss packages" (#10216)"

This reverts commit 3968923.

* Revert "Update postcss packages" (#10216)

This reverts commit 580ed5d.

* Update postcss and loader

* Update [email protected]

References:
* [hook rename](TypeStrong/fork-ts-checker-webpack-plugin#490)
* [include/exclude](TypeStrong/fork-ts-checker-webpack-plugin#450) and [issue options](https://github.com/TypeStrong/fork-ts-checker-webpack-plugin#issues-options)
* [release notes 5.0.0](https://github.com/TypeStrong/fork-ts-checker-webpack-plugin/releases/tag/v5.0.0)

* Update fork-ts-checker-webpack-plugin 6.0.5

* Add [email protected] remove

Add [email protected]
Remove optimize-css-assets-webpack-plugin and postcss-safe-parser

References:
* https://webpack.js.org/plugins/css-minimizer-webpack-plugin/

* Add support for Webpack 5 message objects

* Update WebpackManifestPlugin to v3.0.0

* Support both "SingleEntryPlugin" and "EntryPlugin"

* Support Webpack 5 IgnorePlugin signature

Reference:
* https://webpack.js.org/plugins/ignore-plugin/#example-of-ignoring-moment-locales
* #10006

* Update webpack and dev server

* Enable persistent cache

* Fix react-error-overlay webpack

* Fix dev server config

* Remove support for SingleEntryPlugin

* update workbox-webpack-plugin

* Fix post css config

* Comment out WebpackManifestPlugin for now having issues with undefined path

* Add fast refresh entries to ModuleScopePlugin

* Format files

* Remove unused variables in start command

* git ignore tsconfig.tsbuildinfo
supporting incremental typescript builds

* simplify output path

review feedback from @kumarlachhani

* Use asset modules in react-scripts

* Use asset modules in react-error-overlay

* eslint-config-react-app typo fix (#10317)

This just fixes a shell snippet in the readme file for this plugin

* Fix link address (#10907)

Replace the Github home link with a link to the repo's main page or a link to the source (https://github.com/CodeByZach/pace/blob/master/pace.js)

* Bump immer version for fixing security issue (#10791)

Bump immer minor version to fix `Prototype Pollution` Security issue.

* test(create-react-app): add integration tests (#10381)

* Revert "Use asset modules in react-error-overlay"

This reverts commit 952f896.

* Disable broken tests for now

* Revert source-map bump in react-error-overlay

* JSON is using default export

* Webpack config: Remove invalid parser configuration

* Fix issue with ModuleScope and babel runtime

* Fix svgr configuration

* Webpack config svg use file-loader instead of url-loader

* Update postcss-normalize

* Fix asset output name

* Update test matrix using node 12+14

postcss normalize only support node >=12

* Fix file output extension

* Align assetModuleFilename

* pipeline update configuration names

* Add back webpack-manifest-plugin

* Fix kitchen sink get actual href value

.href is prefixed with http://localhost etc.

* Update kitchen sink test to webpack 5 asset modules

* Let webpack handle global this

* Fix eject copy config/webpack/persistentCache folder

* Move tsbuildinfo into cache folder

* Update dependencies

* Update webpack-dev-server to beta.3

* Compilation.modules changed to type Set

reference: comment by @slorber #9994 (comment)

* Format JsonInclusion.js using prettier

* Run prettier on webpack dev server config

* Enable e2e behavior tests using node 12+14

* Comment out e2e behavior tests for now

* Add experimental support for module federation

* Fix missing wds socket path update

accordingly to review by @xiaokekeT

* Revert "Add experimental support for module federation"

This reverts commit 8fdc63b.

Co-authored-by: Ian Schmitz <[email protected]>
Co-authored-by: jasonwilliams <[email protected]>
Co-authored-by: Joseph Atkins-Turkish <[email protected]>
Co-authored-by: e-w-h <[email protected]>
Co-authored-by: Shamprasad RH <[email protected]>
Co-authored-by: James George <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants