Use ES modules instead of CommonJS as a build target #1295
Labels
cli-package
igniteui-cli package
codegen-angular-schematics
core
@igniteui/cli-core package
🆕 status: new
templates
component OR scenario template
🚶 priority: medium
Description
The implementation of
ig update
- #1057 - requires the usage of external code that is written in a separate module, and is possibly/preferably exported in a default async member. This means that we need to be able to dynamically import that module wherever it is supposed to be executed. Similar to whatAngular
are doing with their schematics.This would require something like this to be implemented:
Currently, the CLI is transpiled to
CommonJS
and the above dynamic import will become a synchronousrequire
call which is incapable of handling an async module without additional code overhead.So moving to
ES modules
is a prerequisite forig update
.There is already a PR that attempts to do this - #1059 - but it's been so long that it's really outdated and it's probably best to be abandoned and started from scratch.
We need these changes to update the CLI's packages (Core: chalk & glob) as they are heavily outdated, which is part of this task.
The text was updated successfully, but these errors were encountered: