A one-line package broke `npm create-react-app`
1–10 of 478 posts
Re: A one-line package broke `npm create-react-app`
#2Re: A one-line package broke `npm create-react-app`
#3EDIT: I wasn't dissing the developers. They have regression, this was just an accident. I was stating it is important. My bad (too late to delete).
Re: A one-line package broke `npm create-react-app`
#4This is much less of an issue when using a lockfile, at least for existing packages/projects.
Re: A one-line package broke `npm create-react-app`
#5Re: A one-line package broke `npm create-react-app`
#6The package referred to in the clickbait title is `is-promise`
declare function isPromise(obj: Promise | S): obj is Promise;
This is, indeed, the only line of exported code in the entire package.I genuinely don't understand the NPM world.
Re: A one-line package broke `npm create-react-app`
#7 function isPromise(obj) {
return !!obj && (typeof obj === 'object' || typeof obj === 'function') && typeof obj.then === 'function';
}Re: A one-line package broke `npm create-react-app`
#8This is why regression suites are important. EDIT: I wasn't dissing the developers. They have regression, this was just an accident. I was stating it is important. My bad (too late to delete).
See https://github.com/then/is-promise/blob/master/.travis.yml (missing v11, v12, v13, v14)
Re: A one-line package broke `npm create-react-app`
#9Re: A one-line package broke `npm create-react-app`
#10This is why regression suites are important. EDIT: I wasn't dissing the developers. They have regression, this was just an accident. I was stating it is important. My bad (too late to delete).
The package does have CI setup, however the test matrix does not cover the latest node versions (which are the ones that are affected). See https://github.com/then/is-promise/blob/master/.travis.yml (missing v11, v12, v13, v14)