Subscribe on changes!

FORMATS multiple parameters are lost

avatar
Oct 20th 2020

Version

3.0.1

Reproduction link

https://github.com/AaronBank/vue-next/compare/master...AaronBank-patch-1#diff-6814bf77564b4f1c92f5861e184e28fe217c080a047fefa8b73a728f755ec45c

Steps to reproduce

yarn build reactivity -f cjs,esm-bundler

yarn run v1.22.10 $ node scripts/build.js reactivity -f cjs,esm-bundler

/Users/aaron/github/master/vue-next/packages/reactivity/src/index.ts → packages/reactivity/dist/reactivity.cjs.js... created packages/reactivity/dist/reactivity.cjs.js in 1.9s

/Users/aaron/github/master/vue-next/packages/reactivity/src/index.ts → packages/reactivity/dist/reactivity.cjs.prod.js... created packages/reactivity/dist/reactivity.cjs.prod.js in 129ms

✨ Done in 3.52s.

What is expected?

Packaging results of cjs and esm-bundler

What is actually happening?

Only cjs is output


Consider modifying the connection method of multiple parameters, such as: modify, as.

(The FORMATS parameter and the --environment method are repeated resulting in missing parameters)

avatar
Oct 23rd 2020
rollup -f cjs,esm-bundler

this is not supported with muitl output format in rollup-cli

avatar
Oct 27th 2020

Ok thanks for reply

avatar
Nov 24th 2020

Sorry for this closed issue, I think the problem still exists. yarn build reactivity -f cjs,esm-bundler will execute build.js file, and create rollup environment dynamically, for example, rollup -c --environment TARGET:reactivity,EVNIRONMENT:cjs,esm-bundle, so far so good, next rollup resolved the environment split by comma, and process.env become this as follows: TARGET: 'reactivity', FORMATS: 'cjs', esm-bundler: 'true' so the command only generated cjs format files.

avatar
Nov 24th 2020

TARGET: 'reactivity', FORMATS: 'cjs', esm-bundler: 'true'

Nice to know this.