Problems with the CLI

Actually it starts to look that way that It would be easier to get to you and show you. (-:
Where are you?

Australia :frowning:

Just downloaded as it suggested using bash… so I suspect the latest version.

I will eventually get this.

I have loaded my entire project up to GIT at si2030. If you can get that going it will show you the issue I have with the address custom template. Let me know if you decide to look in that direction.

@Alexander-Taran I am quite sure this is a cli bug on Windows. All I did was npm i -g aurelia-cil, then au new something, and I saw that @si2030 described.

But I am not the right person to investigate since I am not a Windows user. Not sure whether Git bash shell had some effect on this.

I got the same issue both with bash and powershell. I thought I would make sure it was not just one thing…

Created an issue for further investigation.

I’ll get to it… not today though

I have read the discussion this morning on the issues with the CLI. I have used the command prompt to get the cli to work however I still get an error in the console. Any idea why and how to get rid of it?

    webpack - dev - server.js:1 C: \Users\simon\Documents\1. AURELIA\CLI\PROJECTS\Typeahead\test\jest - pretest.ts
    [tsl] ERROR in C:\Users\simon\Documents\1. AURELIA\CLI\PROJECTS\Typeahead\test\jest - pretest.ts(3, 9)
    TS2305: Module '"C:/Users/simon/Documents/1. AURELIA/CLI/PROJECTS/Typeahead/node_modules/aurelia-pal-nodejs/dist/index"' has no exported member 'globalize'.

@si2030, according the info in the issue. That is a separate Webpack4 issue, you need to manually update your package.json to force using webpack3.

Im not sure how to do that. Can you point me in the right direction of possible.

Looks like webpack 4.1.1 is enough to fix it.
Find “webpack”: “^4.2.x”, change it to “webpack”: “^4.1.1”, remove your node_modules folder, package-lock.json or yarn.lock file. Then reinstall everything with npm i or yarn.

But I am not a webpack user, I might missed something. In case you have other issue, I believe @fkleuver would love to help.

Sadly I was already on 4.1.1

I did delete both the node-modules and the package lock file and re installed the node-modules folder… However I am still getting the same error.

in bash I am getting this readout… it serves and the project does run but it has that error.

    $ au run --watch
Starting 'configureEnvironment'...
Finished 'configureEnvironment'
Starting 'runWebpack'...
Project is running at http://localhost:8080
webpack output is served from /
Content not from webpack is served from C:\Users\simon\Documents\1. AURELIA\CLI\PROJECTS\Typeahead\dist
404s will fallback to /index.html
Finished 'runWebpack'
i 「wdm」: wait until bundle finished: /
× 「wdm」: Hash: 0f40a5fcd35bb397b4fc
Version: webpack 4.4.1
Time: 6857ms
Built at: 2018-3-30 14:05:20
                                Asset       Size  Chunks                    Chunk Names
  app.0f40a5fcd35bb397b4fc.bundle.js   3.35 MiB     app  [emitted]  [big]  app
vendor.0f40a5fcd35bb397b4fc.bundle.js    489 KiB  vendor  [emitted]  [big]  vendor
                          index.html  589 bytes          [emitted]
Entrypoint app [big] = app.0f40a5fcd35bb397b4fc.bundle.js
Entrypoint vendor [big] = vendor.0f40a5fcd35bb397b4fc.bundle.js
[./node_modules/aurelia-bootstrapper/dist/native-modules/aurelia-bootstrapper.js] 5.17 KiB {app} [built]
[./node_modules/aurelia-loader-webpack/dist/native-modules/aurelia-loader-webpack.js] 14.4 KiB {app} [built]
[./node_modules/aurelia-pal/dist/native-modules/aurelia-pal.js] 2.18 KiB {app} [built]
[./node_modules/aurelia-polyfills/dist/native-modules/aurelia-polyfills.js] 24.4 KiB {app} [built]
[./node_modules/aurelia-webpack-plugin/runtime/empty-entry.js] 585 bytes {app} [built]
[./node_modules/aurelia-webpack-plugin/runtime/pal-loader-entry.js] 1.56 KiB {app} [built]
[./node_modules/bluebird/js/browser/bluebird.js] 175 KiB {vendor} {app} [built]
[./node_modules/bluebird/js/browser/bluebird.js-exposed] 65 bytes {vendor} {app} [built]
[./node_modules/process/browser.js] 5.29 KiB {vendor} {app} [built]
[./node_modules/webpack/buildin/global.js] (webpack)/buildin/global.js 509 bytes {vendor} {app} [built]
[aurelia-framework] ./node_modules/aurelia-framework/dist/native-modules/aurelia-framework.js 14 KiB {app} [built]
[aurelia-pal-browser] ./node_modules/aurelia-pal-browser/dist/native-modules/aurelia-pal-browser.js 16.9 KiB {app} [built]
[main] ./src/main.ts 1.17 KiB {app} [built]
  [0] multi aurelia-webpack-plugin/runtime/empty-entry aurelia-webpack-plugin/runtime/pal-loader-entry aurelia-webpack-plugin/runtime/empty-entry aurelia-webpack-plugin/runtime/pal-loader-entry aurelia-bootstrapper 76 bytes {app} [built]
  [1] multi bluebird 28 bytes {vendor} [built]
    + 93 hidden modules

ERROR in C:\Users\simon\Documents\1. AURELIA\CLI\PROJECTS\Typeahead\test\jest-pretest.ts
[tsl] ERROR in C:\Users\simon\Documents\1. AURELIA\CLI\PROJECTS\Typeahead\test\jest-pretest.ts(3,9)
      TS2305: Module '"C:/Users/simon/Documents/1. AURELIA/CLI/PROJECTS/Typeahead/node_modules/aurelia-pal-nodejs/dist/index"' has no exported member 'globalize'.
Child html-webpack-plugin for "index.html":
        Asset      Size  Chunks  Chunk Names
    index.html  1.36 MiB       0
    Entrypoint undefined = index.html
    [./node_modules/html-webpack-plugin/lib/loader.js!./index.ejs] 1.03 KiB {0} [built]
    [./node_modules/lodash/lodash.js] 527 KiB {0} [built]
    [./node_modules/webpack/buildin/global.js] (webpack)/buildin/global.js 509 bytes {0} [built]
    [./node_modules/webpack/buildin/module.js] (webpack)/buildin/module.js 519 bytes {0} [built]
i 「wdm」: Failed to compile.

Here is my package .json - its pretty much vanilla with the exception of trying to add aurelia-bootstrap and fetch.

  "name": "typeahead",
  "description": "An Aurelia client application.",
  "version": "0.1.0",
  "repository": {
    "type": "???",
    "url": "???"
  "license": "MIT",
  "dependencies": {
    "aurelia-bootstrapper": "^2.2.0",
    "aurelia-animator-css": "^1.0.4",
    "bluebird": "^3.5.1",
    "aurelia-polyfills": "^1.3.0",
    "aurelia-bootstrap": "^0.1.20",
    "aurelia-fetch-client": "^1.3.1",
    "bootstrap": "^3.3.7",
    "fetch": "^1.1.0",
    "isomorphic-fetch": "^2.2.1"
  "peerDependencies": {},
  "devDependencies": {
    "aurelia-cli": "^0.33.0",
    "aurelia-testing": "^1.0.0-beta.4.0.0",
    "aurelia-tools": "^2.0.0",
    "gulp": "github:gulpjs/gulp#4.0",
    "minimatch": "^3.0.4",
    "through2": "^2.0.3",
    "uglify-js": "^3.3.15",
    "vinyl-fs": "^3.0.2",
    "ts-loader": "^4.0.1",
    "ts-node": "^5.0.1",
    "@types/node": "^9.4.7",
    "@types/lodash": "^4.14.105",
    "@types/webpack": "^4.1.1",
    "typescript": "^2.7.2",
    "jest": "^22.4.2",
    "jest-cli": "^23.0.0-alpha.0",
    "gulp-util": "^3.0.8",
    "aurelia-loader-nodejs": "^1.0.1",
    "aurelia-pal-nodejs": "^1.0.0-beta.3.2.0",
    "ts-jest": "^22.4.1",
    "@types/jest": "^22.2.0",
    "jasmine-core": "^3.1.0",
    "karma": "^2.0.0",
    "karma-chrome-launcher": "^2.2.0",
    "karma-coverage": "latest",
    "karma-jasmine": "^1.1.1",
    "karma-mocha-reporter": "latest",
    "karma-webpack": "latest",
    "karma-coverage-istanbul-reporter": "^1.4.2",
    "jest-jasmine2": "^23.0.0-alpha.0",
    "jest-matchers": "^20.0.3",
    "karma-typescript-preprocessor": "^0.3.1",
    "gulp-rename": "^1.2.2",
    "html-webpack-plugin": "^3.0.6",
    "copy-webpack-plugin": "^4.5.1",
    "extract-text-webpack-plugin": "next",
    "aurelia-webpack-plugin": "^3.0.0-rc.1",
    "webpack": "^4.1.1",
    "webpack-cli": "^2.0.12",
    "webpack-dev-server": "^3.1.1",
    "expose-loader": "^0.7.5",
    "style-loader": "^0.20.3",
    "url-loader": "^1.0.1",
    "del": "^3.0.0",
    "css-loader": "^0.28.11",
    "nps": "^5.8.2",
    "nps-utils": "^1.5.0",
    "file-loader": "^1.1.11",
    "json-loader": "^0.5.7",
    "html-loader": "^0.5.5",
    "istanbul-instrumenter-loader": "^3.0.0",
    "opn": "^5.3.0",
    "webpack-bundle-analyzer": "latest"
  "jest": {
    "modulePaths": ["<rootDir>/src", "<rootDir>/node_modules"],
    "moduleFileExtensions": ["js", "json", "ts"],
    "transform": {
      "^.+\\.(ts|tsx)$": "<rootDir>/node_modules/ts-jest/preprocessor.js"
    "testRegex": "\\.spec\\.(ts|js)x?$",
    "setupFiles": ["<rootDir>/test/jest-pretest.ts"],
    "testEnvironment": "node",
    "collectCoverage": true,
    "collectCoverageFrom": [
    "coverageDirectory": "<rootDir>/test/coverage-jest",
    "coverageReporters": ["json", "lcov", "text", "html"]
  "engines": {
    "node": ">= 6.0.0"
  "scripts": {
    "start": "nps",
    "test": "nps test"
  "main": "dist/app.bundle.js"

Not sure, maybe you can try “webpack”: “4.1.1” to force it.

Ok so I did amend this to so it forced webpack to be 4.1.1 and unfortunately I am still getting the same error. :frowning:

It was discussed in great detail @ issue
It is git-bash issue

Alex, he is talking about au run, which is unlikely git bash issue.

Run is also discussed there as well.
It’s a webpack 4.2 issue
just have to run it with --watch

Hi Alex,

It runs however I am getting this error when it runs.

The error is highlighted above in latter post.

It may well be an error with webpack.

This was all in the interests of trying to produce an issue I was having with custom template binding and aurelia-bootstrap.

I am now unable to get gitrun to work and now I find CLI is also particularly hard to get going. I would like to just show you the fact that you cannot update an aurelia-bootstrap typeahead box from within the custom template but bugger me if I cant get any of these options to work… This was the last problem I had and its turned out to be a show stopper.

ts-loader tries to compile all of the ts ahead of the time…
modyfy webpack.config:
{ test: /\.tsx?$/, loader: "ts-loader" , options: { configFile : 'tsconfig.webpack.json' }},
and add tsconfig.webpack.json to root of your project with contents like this

  "compileOnSave": false,
  "compilerOptions": {
    "target": "es5",
    "module": "esnext",
    "emitDecoratorMetadata": true,
    "experimentalDecorators": true,
    "moduleResolution": "node",
    "sourceRoot": "src",
    "sourceMap": true,
    "allowJs": true,
    "baseUrl": "src",
    "skipLibCheck": true,
    "lib": [
      "es2017", "dom"
  "include": [

1 Like

I do love an “A-ha…” moment!

Working perfectly. Thankyou Alex!

1 Like

this tip should be added to the VS template ! it’s a must have !!

1 Like