0

I made a clone of ngx-bootstrap git-hub project and followed the instructions to build, but always get error.

Build instructions:

First time

clone repository

npm install

npm run test

Output:

> [email protected] pretest C:\Git\ngx-bootstrap
> run-s lint build link


> [email protected] lint C:\Git\ngx-bootstrap
> exit 0


> [email protected] build C:\Git\ngx-bootstrap
> run-s build.ngm build.sass build.es2015


> [email protected] build.ngm C:\Git\ngx-bootstrap
> ngm build -p src --clean

[13:23:44] Clean dist folders [started]
[13:23:44] Cleaning dist [started]
[13:23:44] Cleaning dist [completed]
[13:23:44] Clean dist folders [completed]
[13:23:44] Copy *.md and license files [started]
[13:23:44] Copy *.md and license files [completed]
[13:23:44] Build package.json files [started]
[13:23:44] Build package.json files [completed]
[13:23:44] Copy source files to temporary folder [started]
[13:23:44] Copying ngx-bootstrap source files to src [started]
[13:23:45] Copying ngx-bootstrap source files to src [completed]
[13:23:45] Copy source files to temporary folder [completed]
[13:23:45] Inline template and style files into the components [started]
[13:23:45] Inlining ngx-bootstrap templates and styles [started]
[13:23:45] Inlining ngx-bootstrap templates and styles [completed]
[13:23:45] Inline template and style files into the components [completed]
[13:23:45] Build projects [started]
[13:23:45] Building ngx-bootstrap (src) [started]
[13:23:55] Building ngx-bootstrap (src) [completed]
[13:23:55] Build projects [completed]
[13:23:55] Copy assets to dist folder [started]
[13:23:55] Copy assets to dist folder [skipped]
[13:23:55] Bundling umd version [started]
[13:23:55] Bundling ngx-bootstrap [started]
 10% building modules 0/1 modules 1 active ...-0!C:\Git\ngx-bootstrap\.tmp\index.ts
[at-loader] Using [email protected] from typescript and "tsconfig.json" from C:\Git\ngx-bootstrap\src\tsconfig.json.
                                     [13:24:03] Bundling ngx-bootstrap [completed]
[13:24:03] Bundling umd version [completed]
[13:24:03] Bundling minified umd version [started]
[13:24:03] Bundling ngx-bootstrap [started]
 10% building modules 0/1 modules 1 active ...-0!C:\Git\ngx-bootstrap\.tmp\index.ts
[at-loader] Using [email protected] from typescript and "tsconfig.json" from C:\Git\ngx-bootstrap\src\tsconfig.json.
                                     [13:24:13] Bundling ngx-bootstrap [completed]
[13:24:13] Bundling minified umd version [completed]
[13:24:13] Clean .tmp folders [started]
[13:24:13] Cleaning C:\Git\ngx-bootstrap\.tmp [started]
[13:24:13] Cleaning C:\Git\ngx-bootstrap\.tmp [completed]
[13:24:13] Clean .tmp folders [completed]

-------------------------------------


> [email protected] build.sass C:\Git\ngx-bootstrap
> node-sass --recursive src --output dist --source-map true --source-map-contents sass

Rendering Complete, saving .css file...
Wrote Source Map to C:\Git\ngx-bootstrap\dist\datepicker\bs-datepicker.css.map
Wrote CSS to C:\Git\ngx-bootstrap\dist\datepicker\bs-datepicker.css
Rendering Complete, saving .css file...
Wrote Source Map to C:\Git\ngx-bootstrap\dist\datepicker\utils\scss\mixins.css.map
Wrote CSS to C:\Git\ngx-bootstrap\dist\datepicker\utils\scss\mixins.css
Rendering Complete, saving .css file...
Wrote Source Map to C:\Git\ngx-bootstrap\dist\datepicker\utils\scss\variables.css.map
Wrote CSS to C:\Git\ngx-bootstrap\dist\datepicker\utils\scss\variables.css
Wrote 3 CSS files to C:\Git\ngx-bootstrap\dist

> [email protected] build.es2015 C:\Git\ngx-bootstrap
> node ./scripts/es2015/bundle.es2015.js

C:\Git\ngx-bootstrap\scripts\es2015\bundle.es2015.js:12
async function createEs2015Bundle() {
      ^^^^^^^^
SyntaxError: Unexpected token function
    at createScript (vm.js:56:10)
    at Object.runInThisContext (vm.js:97:10)
    at Module._compile (module.js:542:28)
    at Object.Module._extensions..js (module.js:579:10)
    at Module.load (module.js:487:32)
    at tryModuleLoad (module.js:446:12)
    at Function.Module._load (module.js:438:3)
    at Module.runMain (module.js:604:10)
    at run (bootstrap_node.js:389:7)
    at startup (bootstrap_node.js:149:9)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] build.es2015: `node ./scripts/es2015/bundle.es2015.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] build.es2015 script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\paulo.larini\AppData\Roaming\npm-cache\_logs\2018-01-17T15_24_15_461Z-debug.log
ERROR: "build.es2015" exited with 1.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] build: `run-s build.ngm build.sass build.es2015`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\paulo.larini\AppData\Roaming\npm-cache\_logs\2018-01-17T15_24_15_497Z-debug.log
ERROR: "build" exited with 1.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] pretest: `run-s lint build link`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] pretest script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\paulo.larini\AppData\Roaming\npm-cache\_logs\2018-01-17T15_24_15_540Z-debug.log

What´s wrong ?

1 Answer 1

1

Perhaps you're using a version of Node.JS that doesn't support async/await, please update Node.JS to 8+

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.