Skip to content

Latest commit

 

History

History
1110 lines (596 loc) · 65 KB

CHANGELOG.md

File metadata and controls

1110 lines (596 loc) · 65 KB

1.2.0 (2019-09-03)

Bug Fixes

  • register non-relative app.css module (710acd7)

Features

  • support dynamic ES6 import (4a07932)

1.1.1 (2019-08-22)

Bug Fixes

  • add ia64 as supported architecture (65d5d3f)

1.1.0 (2019-08-19)

Bug Fixes

  • hmr: check for hot update should not create new file (c9656a9)

Features

1.0.3 (2019-08-05)

Bug Fixes

1.0.2 (2019-07-26)

Bug Fixes

  • 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)

Bug Fixes

  • 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)

Bug Fixes

  • 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)

Features

BREAKING CHANGES:

  • the file names of the NativeScript pages are not required to end with -page or -root. All xml, css, js, ts and scss 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)

Bug Fixes

  • 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)

Bug Fixes

  • import the workaroundResolve funciton based on the Angular version (it was moved from compiler_host to utils in Angular 8) (#904) (56224a8)

Features

0.22.0 (2019-05-15)

Bug Fixes

  • 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)

Features

  • 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)

Bug Fixes

  • add support for executing unit tests for vue projects (#870) (c8afe9f)

0.21.1 (2019-04-18)

Bug Fixes

  • 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)

Bug Fixes

  • 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)

Features

0.20.3 (2019-03-14)

Bug Fixes

  • 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)

Features

0.20.1 (2019-02-18)

Bug Fixes

  • add a typescript module resolution when searching for the main Angular module location (#800) (e2714f2)

Features

  • allow angular resolver configuration via webpack.config (4f3e8a6)
  • backwards compatible angular resolver options (c9fc731)

0.20.0 (2019-02-08)

Bug Fixes

  • some packages are treated as externals when they shouldn't (#771) (3362cd6)

Features

  • 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)

BREAKING CHANGES

  • 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.

Migration

Please, refer to this wiki page for detailed information.

0.19.2 (2019-02-01)

Bug Fixes

  • optimize platform specific files resolver (#782) (fb52c53)

0.19.1 (2019-01-28)

Bug Fixes

0.19.0 (2019-01-03)

Bug Fixes

Features

  • TypeScript: use ts-loader instead of awesome-typescript-loader (#738) (7f67198)

BREAKING CHANGES

  • 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)

Bug Fixes

  • JS/TS: use webpack resolver instead of Node.js resolver (#681) (9adc7e7)
  • Vue: resolve full path for entry module (#744) (4d31ea0), closes #742

Features

0.18.3 (2018-12-10)

Bug Fixes

  • project's package.json indentation is not persisted (#727) (a45a45c)

0.18.2 (2018-12-06)

Bug Fixes

  • avoid getting js template in a ts project (#717) (c121c24)

Features

0.18.1 (2018-12-03)

Bug Fixes

  • avoid getting js template in a ts project (#717) (c121c24)

0.18.0 (2018-11-13)

Bug Fixes

Features

  • 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)

Bug Fixes

0.16.3 (2018-10-25)

Bug Fixes

0.17.0-rc.0 (2018-10-17)

Bug Fixes

  • 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)

Features

0.16.2 (2018-09-28)

Bug Fixes

0.16.1 (2018-09-17)

Bug Fixes

  • angular: AoT rebuild on template and style changes (#659) (d812d5d), closes #641

0.16.0 (2018-09-10)

Features

0.15.1 (2018-08-07)

Bug Fixes

0.15.0 (2018-07-24)

Bug Fixes

  • angular: fix livesync for platform-specific files (#615) (93c5f77), closes #611 #601
  • array env args are serialized when sent to webpack (#614) (bfecb8c)

Features

  • 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)

Bug Fixes

  • 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

Migration

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)

Bug Fixes

  • 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

Features

0.14.1 (2018-06-22)

Bug Fixes

Features

  • add platform matching host for AngularCompilerPlugin (#539) (979f732), closes #547
  • make webpack deps production deps of the plugin (#571) (ba68a1b), closes #569

BREAKING CHANGES

  • 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:

  1. Remove all obsolete dependencies from your project. You can do that by invoking the script:
./node_modules/.bin/update-ns-webpack --deps
  1. [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)

Bug Fixes

Features

  • make webpack deps production deps of the plugin (#571) (ba68a1b), closes #569

BREAKING CHANGES

  • 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:

  1. Remove all obsolete dependencies from your project. You can do that by invoking the script:
./node_modules/.bin/update-ns-webpack --deps
  1. [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)

Features

  • add platform matching host for AngularCompilerPlugin (#539) (979f732), closes #547

Bug Fixes

  • Webpack recompile fails when using AoT with watch mode (#547) (979f732), closes #547

0.12.0 (2018-05-30)

You can follow the Migration guide for upgrading to this version.

Bug Fixes

  • 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)

Features

0.11.0 (2018-04-25)

Bug Fixes

  • allow using the plugin via symlink (#501) (a7acb4d)
  • bundling of Angular apps using linked TS plugins (#505) (41779ad)

Features

  • configure v8Version for snapshot tools (#503) (cf0d76b)

BREAKING CHANGES

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 and projectRoot. The usage inside the project's webpack.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)

Bug Fixes

  • hooks: do not set INIT_CWD on any hook (#494) (afe6208)

0.10.1 (2018-04-11)

Bug Fixes

  • 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.

Bug Fixes

Features

BREAKING CHANGES

  • 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)

Bug Fixes

  • 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)

Bug Fixes

Features

0.9.0 (2017-12-20)

You can follow the Migration guide for upgrading to this version.

Bug Fixes

  • 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)

Features

  • 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)

Features

  • add support for web workers to default template (#269) (494ccbb)

0.7.3 (2017-07-12)

Bug Fixes

  • ns-bundle: remove command escaping when spawning child process (#218) (28e3aad), closes #214

0.7.2 (2017-07-05)

Bug Fixes

  • 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)

Features

  • 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)

Bug Fixes

  • mangle-excludes: add Compat Query and Close listener classes (#190) (5791cfc)

Features

  • introduce support for v8 heap snapshot generation (1b5dcdc)
  • add BundleAnalyzerPlugin to webpack config (ac32b14)

0.6.3 (2017-06-09)

Bug Fixes

  • npm scripts: replace deprecated build-app script on postinstall (#184) (a4e7f1c), closes #183

0.6.2 (2017-06-06)

Bug Fixes

  • 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)

Bug Fixes

  • ns-bundle: add missing return (#167) (cd7ea25)
  • ns-bundle: parse all '*-app' flags as tns commands (#166) (8e7a1b3)

Features

  • add publish-ios-bundle npm script (c424a8a)

0.6.0 (2017-05-29)

Bug Fixes

  • 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

Features

  • add UrlResolvePlugin for platform-specific template/style urls (#155) (2ccf55b), closes #75

BREAKING CHANGES:

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)

Bug Fixes

  • 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)

BREAKING CHANGES:

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)

Bug Fixes

  • 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)

Bug Fixes

  • 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)

Features

  • ns-bundle: app can be just prepared and bundled now (#126) (b0688b4)

0.4.0 (2017-04-20)

Bug Fixes

  • 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

Features

  • detect required devDeps versions (9b102c3)

0.3.7 (2017-03-31)

Bug Fixes

  • uglify: exclude tns 3.0 listener impls from mangling (#102) (6666191)

Features

  • update to Angular 4.0 and pin @ngtools/webpack version (#107) (247e507)

0.3.6 (2017-03-08)

Bug Fixes

  • plugins: add additional check for node.text in StyleUrlResolvePlugin (#95) (4a1b625), closes #92

0.3.5 (2017-02-28)

Bug Fixes

  • 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

Features

  • deps: update to @ngtools/webpack v1.2.10 (#84) (70e60a6)

0.3.4 (2017-02-16)

Bug Fixes

  • 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)

Features

  • scripts: add ns-bundle and verify-bundle (#69) (e80cbdc)

0.3.3 (2017-02-01)

Bug Fixes

  • exclude from mangling EditableTextBase (#60) (226f354)
  • register elements from embedded templates (#56) (05f33ed), closes #55
  • uglify: Exclude layout classes from mangling. (75bdeb1)

Features

  • deps: add support for webpack 2.2+ (5c00f2d)

0.3.2 (2017-01-16)

Features

0.3.1 (2017-01-11)

Bug Fixes

  • add typescript@~2.0.10 to ng projects (#48) (87741a1)
  • use AoT entry module if it exists (b8c4f1c)

Features

  • add plugin to support android/ios styleUrls (#47) (be12c23), closes #36
  • support @ngtools/webpack-1.2.1 (71d7823)
  • use the nativescript fork of css-loader (3b6a1c8)