darekf77 / ng2-logger

Isomorphic logger for Browser and NodeJS, ( typescript / javascript ) apps
MIT License
61 stars 17 forks source link

Angular Package Spec #42

Closed CarstenLeue closed 5 years ago

CarstenLeue commented 6 years ago

The modules does not follow the Angular module spec (https://docs.google.com/document/d/1CZC2rcpxffTDfRDs6p1cfbmKNLA6x5O-NtkJglDaBVs/preview).

One aspect that spec mandates is that the module should be available as es5. I think that's true for the ng2-logger itself but not for the chalk dependency. As a consequence an application using this lib and compiling to es5 (then using webpack to create the bundle) will not be es5 compatible. That in turn is a problem for the crawlability of the resulting app, i.e. the google crawler will not be able to crawl the application.

Would it be possible to create a bundle according to the angular module spec (e.g. using ng-packagr)?

darekf77 commented 5 years ago

on angular 7 everything aon frontend when we are using "ng2-logger/browser" everything should be fine and optimised... I can't see reasons to use ng-packagr... it is small library anyway.. I have never used google crawler .. so please @CarstenLeue check if the problem still exists..

CarstenLeue commented 5 years ago

The browser module does not contain the chalk dependency, this works. Thanks