Skip to content
This repository was archived by the owner on Jun 1, 2025. It is now read-only.

Commit c456c35

Browse files
committed
refactor(chore): add instruction to remove build warnings
1 parent 0087dd2 commit c456c35

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

README.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,24 @@ Check out the [Releases](https://github.com/ghiscoding/Angular-Slickgrid/release
3838
- version `2.x.x` for Angular 7+
3939
- since version `2.11.0`, you can also change your build `target` to `ES2015` for modern browser.
4040

41+
#### Build Warnings (Angular 8+)
42+
Since Angular 8+, a few warnings starting to appear in the while doing a Prod build and this was asked a few separate issues. These warnings are **fine**, the reason is because I dynamically load all the SlickGrid extensions [here](https://github.com/ghiscoding/Angular-Slickgrid/blob/master/src/app/modules/angular-slickgrid/extensions/extensionUtility.ts#L29) and depending on which flags you use in the grid options, with `require('slickgrid/plugins/slick....');` and Angular is complaining about the use of `require`.
43+
44+
The warnings are **normal** so the best way to fix this, is to simply remove the warnings, all you have to do is to add a file named `ngcc.config.js` in your project source root with the following content (you can also see this [commit](https://github.com/ghiscoding/angular-slickgrid-demos/commit/1fe8092bcd2e99ede5ab048f4a7ebe6254e4bee0) which fixes the Angular-Slickgrid-Demos):
45+
```js
46+
module.exports = {
47+
packages: {
48+
'angular-slickgrid': {
49+
ignorableDeepImportMatchers: [
50+
/slickgrid\//,
51+
/flatpickr/,
52+
/jquery-ui-dist\//,
53+
]
54+
},
55+
}
56+
};
57+
```
58+
4159
### Fully Tested with [Jest](https://jestjs.io/) (Unit Tests) - [Cypress](https://www.cypress.io/) (E2E Tests)
4260
Angular-Slickgrid reached **100%** Unit Test Coverage, we are talking about ~10,000 lines of code (+2,600 unit tests) that are now fully tested with [Jest](https://jestjs.io/). There are also over 300 Cypress E2E tests to cover most UI functionalities.
4361

0 commit comments

Comments
 (0)