select2-component icon indicating copy to clipboard operation
select2-component copied to clipboard

Impossible to build the project

Open Zefling opened this issue 6 years ago • 3 comments

With nodejs 10.4.1 and npm 6.1.0, I have this problem with Ubuntu:

$ npm run dev

> select2-component@ dev /mnt/c/sources/select2-component
> export NODE_ENV=development && clean-scripts build

ngc -p packages/core/src
lessc packages/core/src/select2.less -sm=on > packages/core/src/select2.css
rimraf "packages/@(core|vue|react|angular)/demo/**/@(*.bundle-*.js|*.bundle-*.css)"
postcss packages/core/src/select2.css -o packages/core/dist/select2.css
cleancss packages/core/dist/select2.css -o packages/core/dist/select2.min.css
cleancss packages/core/dist/select2.min.css ./node_modules/github-fork-ribbon-css/gh-fork-ribbon.css -o packages/core/demo/index.bundle.css
ngc -p packages/core/demo
file2variable-cli --config packages/vue/src/file2variable.config.js
tsc -p packages/react/src
file2variable-cli packages/angular/src/index.template.html -o packages/angular/src/variables.ts --html-minify --base packages/angular/src
file to variable success.
Success: to "packages/angular/src/variables.ts".
ngc -p packages/angular/src
file to variable success.
Success: to "packages/vue/src/variables.ts".
tsc -p packages/vue/src
packages/react/src/index.tsx(3,25): error TS2307: Cannot find module 'select2-component'.
packages/react/src/index.tsx(4,15): error TS2307: Cannot find module 'select2-component'.
packages/react/src/index.tsx(145,45): error TS7006: Parameter 'groupOrOption' implicitly has an 'any' type.
packages/react/src/index.tsx(145,60): error TS7006: Parameter 'i' implicitly has an 'any' type.
packages/react/src/index.tsx(148,46): error TS7006: Parameter 'option' implicitly has an 'any' type.
packages/react/src/index.tsx(148,54): error TS7006: Parameter 'j' implicitly has an 'any' type.
packages/react/src/index.tsx(259,5): error TS2322: Type 'number' is not assignable to type 'Timer | undefined'.
Command failed: tsc -p packages/react/src

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! select2-component@ dev: `export NODE_ENV=development && clean-scripts build`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the select2-component@ dev 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!     /home/user/.npm/_logs/2018-06-25T15_39_35_141Z-debug.log

On Windows:

$ npm run dev

> select2-component@ dev C:\sources\select2-component
> export NODE_ENV=development && clean-scripts build

'export' n’est pas reconnu en tant que commande interne
ou externe, un programme exécutable ou un fichier de commandes.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! select2-component@ dev: `export NODE_ENV=development && clean-scripts build`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the select2-component@ dev 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\CVeyssiere\AppData\Roaming\npm-cache\_logs\2018-06-25T15_44_33_861Z-debug.log

Zefling avatar Jun 25 '18 15:06 Zefling

The first issue seems lerna bootstrap before yarn dev, the second one seems comes from export NODE_ENV=development, you can just yarn build

plantain-00 avatar Jun 25 '18 23:06 plantain-00

Now yarn dev should work too on windows

plantain-00 avatar Jun 25 '18 23:06 plantain-00

Ok, thanks.

It works for me on Windows with:

npm i yarn
npm run bootstrap
npm run dev

I try to update on Angular 6 for our project.

Zefling avatar Jun 26 '18 09:06 Zefling