1.5.1 (2020-02-25)
The provided Android NDK is vnull while the recommended one is v21.0.6113669
error in some cases (23aa6c5)- AOT compilation of multiple workers should work (af5cb84)
- replace extension coming from package.json (a04c0f8)
1.5.0 (2020-02-04)
- ensure the js snapshot entry dir if not created (avoid ENOENT error) (2a0eaf6)
- stop searching for snapshot artefacts when the snapshot tools are skipped (it's a cloud build, there aren't any snapshot artefacts locally) (b8da140)
- dependencies: updated
[@angular](https://github.com/angular)/compiler-cli
dependency (1dbcbf2), closes #1114 - allow extending webpack.config.js through env (69ace1e)
1.4.1 (2020-01-07)
- add missing tsconfig paths when the app is using only scoped modules and angular (87ec157)
- handle missing paths obj in tsconfig (867a9f1)
1.4.0 (2019-12-08)
- add import of
.css
file into another.css
file (c5e4552) - avoid duplicate modules from tns-core-modules and @nativescript/core causing app crashes on Android (b74b231)
- bundle emitted on save without changes (2d01df9), closes /github.com/webpack/webpack/blob/4056506488c1e071dfc9a0127daa61bf531170bf/lib/Compiler.js#L326
- fix module import of local css files (2c0a36e), closes /github.com/webpack-contrib/css-loader/blob/967fb66da2545f04055eb0900a69f86e484dd842/src/utils.js#L220
- remove the tns-core-modules dependency in order to allow @nativescrip/core migration (7d60958)
- stop ignoring the initial hot updates (d032e4c)
- stop on compilation error in typescript applications (df7d122)
- update worker loader in order to fix HMR (5ad141e)
- snapshot in Docker on macOS with Android runtime 6.3.0 or higher as it will not contain snapshot tools for macOS anymore (9e99683)
- stop using the proxy
tns-core-modules
package when the[@nativescript](https://github.com/nativescript)/core
is available (061b270)
1.3.0 (2019-10-31)
- exclude files from tests folder from built application (c61f10e)
- fix dependencies in package.json (eefd042), closes /github.com/NativeScript/nativescript-dev-webpack/blob/master/bundle-config-loader.ts#L4 /github.com/NativeScript/nativescript-dev-webpack/blob/2978b81b5a8100774b2bb4a331ac8637205927b8/package.json#L54
- fix xxd path for local snapshots generation (f63d493)
- handle correctly webpack compilation errors (363c4da)
- handle imports like @import url("./xxx.css") (8921120)
- search for the proper NDK executable on Windows (f93bb6c)
- Unbound namespace error with ios and android (#1053) (6cd6efe)
- add useForImports option (632af4f)
- ensure valid CLI version when Windows snapshot is requested (3a687c0)
- support @nativescript scope in host resolver (efda509)
- support useLibs though env.compileSnapshot and calculate the NDK path internally (5431bd7)
- support V8 snapshots on Windows (2e9b753)
- use css2json loader by default (6b0c9ae)
1.2.1 (2019-10-03)
- snapshot in docker container when the local tools are not available (6861d22)
1.2.0 (2019-09-03)
- register non-relative app.css module (710acd7)
- support dynamic ES6 import (4a07932)
1.1.1 (2019-08-22)
- add ia64 as supported architecture (65d5d3f)
1.1.0 (2019-08-19)
- hmr: check for hot update should not create new file (c9656a9)
- update to angular 8.2 (d13441a)
1.0.3 (2019-08-05)
- crash with source-map instead of inline-source-map (#968) (ff07d6c)
- update-ns-webpack: skip the update of tsconfig.tns.json in… (#1001) (2ed9850)
1.0.2 (2019-07-26)
- do not require
.js.map
files in the entry points when someone is using devtool: "source-map" (#968) (4bb6124) - avoid getting invalid require calls when building from Windows (#989) (4799271)
- escape the regex for the path to the entry module of application (#998) (571c7f2)
1.0.1 (2019-07-16)
- don't include partial scss files in bundle (#988) (786bd6c)
- js: try to resolve node_modules from the project root before resolving in a linked location (#987) (a3df142)
1.0.0 (2019-07-10)
- allow overriding the
global.process
object from both the app and the plugins (8c4292e) - auto accept new or deleted files (#972) (bd893ce)
- avoid generating invalid JavaScript when merging IIFE files (7586d4c)
- create PropertyAssignment instead of string literal (Identifier) when modifying the NgModule - in some cases (e.g. when there is a decomposition in another NgModule property), the TypeScipt program is trying to read
node.name.kind
on each property causing an exception for Identifiers) (a70fb3b) - do not add inspector_modules entry when core modules are an external module (e0cd8c1)
- do not show warning for format differences in templates (#947) (a352064)
- don't restart application when lazy loaded code is changed in angular app with uglify option (121c3b2)
- emit inspector_modules as a module (be2a5a6)
- fix app.css file path on windows machines (7d734d8)
- fix hmr for platform specific files in linked plugins (#946) (9e8c921)
- follow the symlinks in JavaScript apps (#941) (f0c62fb)
- hmr should work with uglify (#953) (874e4f8)
- xml-ns-loader: remove wrong register of xml (#940) (bc2f6f1)
- inject app.css file from unit-test-runner on test command (#949) (a216ed3)
- log the real snapshot tool error by trying to evaluate the input file script (1a9c4b2)
- migrate demo apps to android x (c2d6684)
- unify the entry points handling and enable custom applications in android (de10041)
- hooks: improve hooks handling (#961) (f558607)
- introduce webpack only workflow (#882) (2de4c68)
- no need of "page" suffix (#966) (d4a8dec)
- support for file qualifiers (#966) (d4a8dec)
- universal hmr loader (#966) (d4a8dec)
-
the file names of the NativeScript pages are not required to end with
-page
or-root
. Allxml
,css
,js
,ts
andscss
files are not included in the bundle. -
the plugin is not working with NativeScript CLI older than 6.0.0 (
nativescript@6.0.0
). -
the Webpack mode it set to
production
based on the--release
flag of the NativeScript CLI, instead of the--env.uglify
one.
0.24.1 (2019-06-06)
- move the type check to a child process in order to make it faster in bigger apps and unify the hmr and no-hmr experience. (#926) (1398179)
- stop generating .d.ts on TS compilation (#919) (ccbf8de)
0.24.0 (2019-05-30)
- import the workaroundResolve funciton based on the Angular version (it was moved from compiler_host to utils in Angular 8) (#904) (56224a8)
0.22.0 (2019-05-15)
- ignore the Webpack runtime chunks when sending HMR updates (be82ab7)
- show proper stack traces from uglified code (split by new line instead of semicolon) (0ae6030)
- sourceMap not generated with Uglify (#819) (b5fd066)
- support platform specific files that are not directly imported anywhere in the app (#843) (e1e9463)
- update the css loader in order to fix a bug with leading dashes of css classes (#847) (7670e33)
- hmr: run ts-loader in transpileOnly mode (#878) (0317729)
- replace UglifyJs with Terser (621090a)
- support hidden source maps to map error stack traces from crash reports (#854) (dbcfbc2)
0.21.2 (2019-04-22)
0.21.1 (2019-04-18)
- add support for ts files on test command when
--bundle
is provided (#848) (bd4fa9c) - fix "ERROR in Must have a source file to refactor." error from ngCompilerPlugin on
test
command (#859) (196d977) - typescript source maps are containing javascript code (#857) (384bee2)
- use correct slashes on windows (#851) (9020c47)
0.21.0 (2019-03-21)
- Emit inspector_modules.js as a separate entry point for iOS (00ecaa0)
- execute bundle-config-loader only for the entry point of the application (#829) (36824b1)
- fix "Cannot read property 'kill' of undefined" error (#822) (8d18853)
- stop deleting chunks with compilation errors in order to avoid outdated app state when deleting files or throwing errors (#836) (69cb061)
- HMR: modulePath on Windows to apply changes in app styles at runtime (#807) (c4b4fee)
- inspector_modules: Switch to
single
runtime chunk (6e780af)
- Implement unit testing with bundle (#835) (7944611)
- Support Angular Ivy modules with AOT (#828) (f476c56)
0.20.3 (2019-03-14)
- initial compilation always generates same compilation hash (#815) (ba6d896)
- show message for stopping webpack only when it has been started (#821) (1bd18e5)
- HMR: modulePath on Windows to apply changes in app styles at runtime (#807) (cc55d4f)
0.20.1 (2019-02-18)
- add a typescript module resolution when searching for the main Angular module location (#800) (e2714f2)
- allow angular resolver configuration via webpack.config (4f3e8a6)
- backwards compatible angular resolver options (c9fc731)
0.20.0 (2019-02-08)
- support HMR in Angular apps (#788) (6a9ce33)
- Angular: apply changes in application styles at runtime with HMR (#748) (fe4abfb)
- snapshot: the parameters passed to mksnapshot are now retrieved… (#789) (cb68dac)
- Hot Module Replacement in NativeScript Angular Project
This version enables the Hot Module Replacement feature in NativeScript Angular projects by default.
So far it was required to add a snippet to enable HMR. With this release, you have to remove any previous module["hot"]
related code so HMR can work out of the box.
However, if you want to continue handling hot changes manually, follow these instructions.
Please, refer to this wiki page for detailed information.
0.19.2 (2019-02-01)
0.19.1 (2019-01-28)
- Vue: apply style changes with HMR (#763) (#777) (8ee1880), closes #744 #742 #762
- debugging: lazy-ngmodule-hot-loader breaks the sourceMaps (#770) (aca851c)
0.19.0 (2019-01-03)
- angular: support angular lazy routes in preview (#753) (a6c23da)
- Angular: add hot loader for lazy loaded NgModules (#747) (6a9db32)
- Vue: disable mangling of function names when building in production mode (#743) (fffcf66), closes /github.com/NativeScript/nativescript-dev-webpack/blob/master/CONTRIBUTING.md#testing-locally-by-running-e2
- Angular: The
lazy-ngmodule-hot-loader
should be added to the webpack configuration.
BEFORE
// webpack.config.js
{
test: /(?:\.ngfactory\.js|\.ngstyle\.js|\.ts)$/,
use: [
"nativescript-dev-webpack/moduleid-compat-loader",
"@ngtools/webpack",
]
},
// ...
AFTER
// webpack.config.js
{
test: /(?:\.ngfactory\.js|\.ngstyle\.js|\.ts)$/,
use: [
"nativescript-dev-webpack/moduleid-compat-loader",
"nativescript-dev-webpack/lazy-ngmodule-hot-loader",
"@ngtools/webpack",
]
},
// ...
0.18.5 (2018-12-17)
- JS/TS: use webpack resolver instead of Node.js resolver (#681) (9adc7e7)
- Vue: resolve full path for entry module (#744) (4d31ea0), closes #742
0.18.3 (2018-12-10)
0.18.2 (2018-12-06)
0.18.1 (2018-12-03)
0.18.0 (2018-11-13)
- Angular 7 support
0.17.0 (2018-10-31)
Version 0.17.0 introduces initial Hot Module Replacement support for plain JavaScript, TypeScript and Vue applications.
Note: find out here how to enable HMR for Angular projects.
For more details, refer to 0.17.0-rc.1 and 0.17.0-rc.0 changelogs below.
0.17.0-rc.1 (2018-10-25)
0.16.3 (2018-10-25)
0.17.0-rc.0 (2018-10-17)
- add a check for undefined environment values (#673) (c81484f)
- uglify: cache/parallel should be outside uglifyOptions (#670) (e15fec7)
- attach to process's exit event on correct place (#671) (f4b40bf)
- add initial HMR support for plain JS/TS apps (#645) (a4ac32b)
- add hook for the preview command (#649) (b47da3c)
- add Vue bundling support (#676) (8da8ccf)
0.16.2 (2018-09-28)
0.16.1 (2018-09-17)
0.16.0 (2018-09-10)
0.15.1 (2018-08-07)
0.15.0 (2018-07-24)
- angular: fix livesync for platform-specific files (#615) (93c5f77), closes #611 #601
- array env args are serialized when sent to webpack (#614) (bfecb8c)
- xml-namespace-loader: add ignore option (#605) (b509bb3), closes #558
- debug: generate source maps when running
tns debug --bundle
(#617)
0.14.3 (2018-07-05)
- Angular projects: the plugin will add
@ngtools/webpack
to the project deps only if@angular-devkit/build-angular
is not a dependency. (#594) (7b15418), closes #595
It's a good idea to remove @angular-devkit/build-angular
from the
package.json and add @ngtools/webpack
instead. This will speed up
the build.
0.14.2 (2018-06-27)
- resolve appComponents and xml namespaces absolute paths on Windows (#578) (14de7e1)
- tell the {N} CLI to ignore the source dir when watching for changes (#586) (6b0f56b), closes #584
0.14.1 (2018-06-22)
- schema-utils peer dep warning for webpack 2/3 (#577) (afe569d)
- AoT: stop using require.context in Angular apps (#574) (23aaee9), closes /github.com/angular/angular-cli/blob/master/packages/ngtools/webpack/src/compiler_host.ts#L235 #566
- add platform matching host for AngularCompilerPlugin (#539) (979f732), closes #547
- make webpack deps production deps of the plugin (#571) (ba68a1b), closes #569
- The dependencies that were previously added by the nativescript-dev-webpack plugin to the project's package.json are now dependencies of the plugin itself.
MIGRATION:
- Remove all obsolete dependencies from your project. You can do that by invoking the script:
./node_modules/.bin/update-ns-webpack --deps
- [Angular] Add the following packages as devDependencies:
//package.json
"devDependencies": {
"@angular-devkit/build-angular": "~0.7.0-rc.0",
"@angular/compiler-cli": "~6.1.0-beta.1",
//...
}
0.14.0 (2018-06-22)
- The dependencies that were previously added by the nativescript-dev-webpack plugin to the project's package.json are now dependencies of the plugin itself.
MIGRATION:
- Remove all obsolete dependencies from your project. You can do that by invoking the script:
./node_modules/.bin/update-ns-webpack --deps
- [Angular] Add the following packages as devDependencies:
//package.json
"devDependencies": {
"@angular-devkit/build-angular": "~0.7.0-rc.0",
"@angular/compiler-cli": "~6.1.0-beta.1",
//...
}
If you see one of the following errors:
Error: Cannot find module '@ngtools/webpack'
Error: No module factory available for dependency type: ContextElementDependency
Error: Cannot find module '/Users/nsbuilduser/workspace/master-nativescript-sdk-examples-js-android/nativescript-sdk-examples-js/node_modules/webpack/bin/webpack.js
try running a clean npm install:
rm -rf node_modules package-lock.json
npm i
0.13.0 (2018-06-13)
0.12.0 (2018-05-30)
You can follow the Migration guide for upgrading to this version.
- allow using the plugin via symlink (#501) (a7acb4d)
- bundling of Angular apps using linked TS plugins (#505) (41779ad)
- bundling of ts apps using linked plugins (#530) (c7117d7)
- register XML-only custom components (#537) (aaf4e88)
- add webpack 4 and Angular 6 support (#495) (eefce39)
- add xml loader for elements from external namespaces (#525) (19bbc7e)
- configure v8Version for snapshot tools (#503) (cf0d76b)
- generate the snapshot entry module at build time (2ec8083), closes #511
- load bundle config and app css at build time (f9bbea9)
- move all node modules to the common chunk (#507) (2ff43bf)
- tweak the uglify configuration to enable compression for android (7a125ee)
- target es2015 modules when bundling using tsconfig.esm.json file. ([8922c96])(https://github.com/NativeScript/nativescript-dev-webpack/commit/8922c9611e756d165ec6ca454c237b6bcb56b8ef)
0.11.0 (2018-04-25)
- allow using the plugin via symlink (#501) (a7acb4d)
- bundling of Angular apps using linked TS plugins (#505) (41779ad)
The command below will overwrite the existing project's webpack configuration files with the most recent ones, so you don't have to manually apply the required changes:
./node_modules/.bin/update-ns-webpack --configs
- The NativeScriptAngularCompilerPlugin is loaded in a different way now. The existing projects using the plugin should add the following line to their
webpack.config.js
file:
// webpack.config.js
module.exports = env => {
const platform = env && (env.android && "android" || env.ios && "ios");
if (!platform) {
throw new Error("You need to provide a target platform!");
}
const platforms = ["ios", "android"];
const projectRoot = __dirname;
nsWebpack.loadAdditionalPlugins({ projectDir: projectRoot }); // <----- Add this line
// ...
- The
getAppPath
method expects two arguments now -platform
andprojectRoot
. The usage inside the project'swebpack.config.js
should be changed in the following way:
Before:
// webpack.config.js
// Default destination inside platforms/<platform>/...
const dist = resolve(projectRoot, nsWebpack.getAppPath(platform));
// ...
After:
// webpack.config.js
// Default destination inside platforms/<platform>/...
const dist = resolve(projectRoot, nsWebpack.getAppPath(platform, projectRoot));
// ...
0.10.2 (2018-04-18)
0.10.1 (2018-04-11)
- configs/angular: use path relative to the appDir for the root (8e7aa0c)
0.10.0 (2018-04-05)
You need NativeScript 4.0 for using the new features from this version.
- hooks:
after-watch
hook is not executed (#483) (a61cff4) - allow snapshot only in release (#448) (2dd9adc)
- clean snapshot artifacts on cleanApp hook (#423) (50c3ab9)
- remove progress indication (#468) (8961a93), closes /github.com/webpack/webpack/blob/4428efe48e1c5ff4cadb79e13f0fa48c12bdac35/lib/ProgressPlugin.js#L50
- remove unnecessary comma (#472) (ce60606)
- send arguments in watchPatterns hook (#449) (aa255bb)
- Set INIT_CWD env in all before-* hooks (#480) (b7ef84f)
- hooks: Hooks not executed correctly when CLI is used as a library (#479) (87dd53d)
- prepare: clean platforms/.../app/ when running webpack (#465) (cb2f51b)
- snapshot: use request module for http requests (#428) (01933e0), closes #389
- uglify: prevent SideDrawer transition class names from being renamed (#426) (0120329), closes /github.com/telerik/nativescript-ui-feedback/issues/477#issuecomment-360772046 #258
- The snapshot plugin is applied only when building for release.
Before:
tns run android --bundle --env.snapshot
After:
tns run android --bundle --env.snapshot --release --keyStorePath ~/path/to/keystore/my.keystore --keyStorePassword password --keyStoreAlias alias --keyStoreAliasPassword aliasPassword
0.9.2 (2018-02-15)
- clean snapshot artifacts on cleanApp hook (#423) (50c3ab9)
- snapshot: use request module for http requests (#428) (01933e0), closes #389
- uglify: prevent SideDrawer transition class names from being renamed (#426) (0120329), closes #258
0.9.1 (2018-01-10)
- respect windows paths in /app.css regex (#385) (a37cca0)
- support aot on windows (#392) (8a20502)
- css: disable minification when using uglify (#383) (8e1a5a6), closes #377
0.9.0 (2017-12-20)
You can follow the Migration guide for upgrading to this version.
- compiler: reject promise with real error (#350) (0b9febe)
- configs: don't follow symlinks for loaders (#287) (7deb117)
- ns-bundle: support for Node.js 9 (#321) (b4800c8)
- postinstall: stop removing "start/run-platform-bundle" scripts (#301) (ddecb56)
- snapshot: interrupt the webpack build on error (#369) (0a6d1b9)
- snapshot: use autoclose option on writestream (#345) (3967d79)
- update-ns-webpack: make it possible to call as executable (#347) (9fa7656)
- Angular 5 support (#328) (5539ddb)
- add FS, PlatformSuffixPlugin and css2json-loader (#290) (ea29bb6)
- Configure the vendor scripts to also use less, sass, scss for app.css (#343) (273dbd5)
- enable plugin to run through {N} CLI hooks (#299) (9a57a53)
- sass: add conditional sass deps for webpack (#355) (f51241c)
0.8.0 (2017-09-08)
0.7.3 (2017-07-12)
0.7.2 (2017-07-05)
- mangle-excludes: add Compat Query and Close listener classes (#190) (5791cfc)
- ns-bundle: escape command and args when spawning child process (c3e7376), closes #209
- run gradlew clean only for tns <=3.0.1 (efea463)
- add support for passing params via --env to webpack (#204) (4921321)
- alias tilde to point to the app root (#201) (3fb865d)
- add BundleAnalyzerPlugin to webpack config (ac32b14)
0.7.1 (2017-06-22)
- introduce support for v8 heap snapshot generation (1b5dcdc)
- add BundleAnalyzerPlugin to webpack config (ac32b14)
0.6.3 (2017-06-09)
0.6.2 (2017-06-06)
- ns-bundle: properly get tns command (#170) (43eeaf4), closes #169
- bundle scripts should invoke tns run instead of tns start (#174) (f3d8a3a), closes #172
- clean android build artifacts when using with uglify (#175) (278244b)
- exclude impl core modules classes from mangling (#173) (53d7538)
0.6.1 (2017-05-31)
- ns-bundle: add missing return (#167) (cd7ea25)
- ns-bundle: parse all '*-app' flags as tns commands (#166) (8e7a1b3)
- add publish-ios-bundle npm script (c424a8a)
0.6.0 (2017-05-29)
- ns-bundle: clean android build for NativeScript CLI 3.0.1<= (#163) (35ce787)
- template: disable minification of css by css-loader (#154) (30e9c97), closes #135
The StyleUrlResolvePlugin is now replaced by the UrlResolvePlugin. The latter replaces both style and template platform-specific urls from Angular components. On postinstall nativescript-dev-webpack will automatically replaces all occurencies of the old plugin in the project's webpack config.
0.5.0 (2017-05-11)
- ns-bundle: don't re-add scripts from nativescript-dev-webpack (3d690cb)
- ns-bundle: pass platform and uglify as env properties (dcf21f8)
- ns-bundle: use webpack.config.js instead of webpack.common.js (3df5d9b)
- template: create empty
tns-java-classes.js
internally (#148) (0fd9159) - templates: prefer css templates over platform.css templates (6fc4747)
The plugin now adds webpack.config.js
file instead of webpack.common.js
, webpack.android.js
and webpack.ios.js
files.
The ns-bundle script targets the webpack.config.js
file in
your repository instead of the webpack.common.js
one. If you modified
your configuration, you need to apply the changes to webpack.config.js
.
The following files are no longer needed and can be safely removed from
the project: webpack.common.js
, webpack.android.js
,
webpack.ios.js
.
0.4.2 (2017-05-04)
- ns-bundle: respect platform version from app package.json (#138) (839ce93)
- tsconfig: add missing paths and skipLibCheck option (#140) (c453944)
0.4.1 (2017-05-01)
- ns-bundle: escape arguments passed to
tns
command (#125) (b9430e3), closes #123 - template: include platform specific files in bundle first (#133) (c399e1e), closes #31
- template: ship android bundle with empty
tns-java-classes.js
chunk (#128) (b65a80c)
0.4.0 (2017-04-20)
- add webpack.common template for JS projects (7451545), closes #113
- installer: show helper message for new dependencies (#122) (5c7ebeb)
- ns-bundle: use remove/add platform instead of clean-app (#116) (6609370)
- tsconfig: add "exclude" property to aot config (#120) (d28dba1), closes #101
- detect required devDeps versions (9b102c3)
0.3.7 (2017-03-31)
0.3.6 (2017-03-08)
0.3.5 (2017-02-28)
- plugins: check for argument properties before traversing (#83) (bc2c6ec)
- scripts: correctly execute ns-bundle for windows (#89) (ad965ed)
- templates: Disable node "fs" shim (#82) (b86e1ae), closes #80
0.3.4 (2017-02-16)
- run
tns-xml-loader
before@ngtools
loader (#66) (325cb90), closes #64 - scripts: respect tns build/run args passed to ns-bundle (#71) (17b9d82)
- uglify: exclude tns 3.0 listeners from mangling (#72) (b9d6a3f)
0.3.3 (2017-02-01)
- exclude from mangling EditableTextBase (#60) (226f354)
- register elements from embedded templates (#56) (05f33ed), closes #55
- uglify: Exclude layout classes from mangling. (75bdeb1)
- deps: add support for webpack 2.2+ (5c00f2d)