Add support for dynamic import & disable require.ensure #1538

Merged
merged 7 commits into from Feb 15, 2017

Conversation

Projects
None yet
5 participants
@Timer
Collaborator

Timer commented Feb 12, 2017

This PR enables babel syntax support for import() and disables require.ensure support within webpack.

It also updates the required internal files.

@Timer Timer added this to the 0.10.0 milestone Feb 12, 2017

Timer added some commits Feb 12, 2017

@Timer Timer changed the title from Disable require.ensure to Add support for dynamic import & disable require.ensure Feb 12, 2017

@Timer Timer referenced this pull request Feb 12, 2017

Closed

Enable webpack v2 performance hints #1529

2 of 5 tasks complete

Timer added some commits Feb 12, 2017

@Timer Timer referenced this pull request Feb 12, 2017

Merged

Bump jsx-a11y version #1542

package.json
@@ -11,7 +11,7 @@
"test": "node packages/react-scripts/scripts/test.js --env=jsdom"
},
"devDependencies": {
- "babel-eslint": "6.1.2",
+ "babel-eslint": "7.1.0",

This comment has been minimized.

@bondz

bondz Feb 12, 2017

Contributor

latest is 7.1.1, could as well use that.

@bondz

bondz Feb 12, 2017

Contributor

latest is 7.1.1, could as well use that.

- "eslint-plugin-jsx-a11y": "2.2.2",
- "eslint-plugin-react": "6.3.0",
+ "babel-eslint": "7.1.0",
+ "eslint": "3.8.1",

This comment has been minimized.

@bondz

bondz Feb 12, 2017

Contributor

latest is 3.15.0

@bondz

bondz Feb 12, 2017

Contributor

latest is 3.15.0

+ "babel-eslint": "7.1.0",
+ "eslint": "3.8.1",
+ "eslint-config-react-app": "0.5.1",
+ "eslint-plugin-flowtype": "2.21.0",

This comment has been minimized.

@bondz

bondz Feb 12, 2017

Contributor

latest is 2.30.0

@bondz

bondz Feb 12, 2017

Contributor

latest is 2.30.0

+ "eslint": "3.8.1",
+ "eslint-config-react-app": "0.5.1",
+ "eslint-plugin-flowtype": "2.21.0",
+ "eslint-plugin-import": "2.0.1",

This comment has been minimized.

@bondz

bondz Feb 12, 2017

Contributor

latest is 2.2.0

@bondz

bondz Feb 12, 2017

Contributor

latest is 2.2.0

@Timer

This comment has been minimized.

Show comment
Hide comment
@Timer

Timer Feb 12, 2017

Collaborator

I tried to keep versions near https://github.com/facebookincubator/create-react-app/blob/master/packages/eslint-config-react-app/package.json since typically we employ exact versions (I forget why it was relaxed in that package); since this is strictly for development tho it might not hurt to bump them.

Same reasoning for #1544.

Collaborator

Timer commented Feb 12, 2017

I tried to keep versions near https://github.com/facebookincubator/create-react-app/blob/master/packages/eslint-config-react-app/package.json since typically we employ exact versions (I forget why it was relaxed in that package); since this is strictly for development tho it might not hurt to bump them.

Same reasoning for #1544.

@bondz

This comment has been minimized.

Show comment
Hide comment
@bondz

bondz Feb 12, 2017

Contributor

Yes, that is the reason I was hoping to have them as the latest version, to avoid the number of duplicate dependencies package managers have to install, like the issues yarn has with modules. Don't think it matters though since they're all peer-deps in that package.

Contributor

bondz commented Feb 12, 2017

Yes, that is the reason I was hoping to have them as the latest version, to avoid the number of duplicate dependencies package managers have to install, like the issues yarn has with modules. Don't think it matters though since they're all peer-deps in that package.

@Timer

This comment has been minimized.

Show comment
Hide comment
@Timer

Timer Feb 12, 2017

Collaborator

note: these deps are only when you're developing on this package locally, it has no effect on create-react-app installs.

We can prob bump them.

Collaborator

Timer commented Feb 12, 2017

note: these deps are only when you're developing on this package locally, it has no effect on create-react-app installs.

We can prob bump them.

@bondz

This comment has been minimized.

Show comment
Hide comment
@bondz

bondz Feb 12, 2017

Contributor

Oh, okay 👍

Contributor

bondz commented Feb 12, 2017

Oh, okay 👍

@Timer

This comment has been minimized.

Show comment
Hide comment
@Timer

Timer Feb 15, 2017

Collaborator

:shipit:

Collaborator

Timer commented Feb 15, 2017

:shipit:

@Timer Timer merged commit fc49946 into facebook:master Feb 15, 2017

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details

@Timer Timer deleted the Timer:require-ensure branch Feb 15, 2017

@douglasmamilor

This comment has been minimized.

Show comment
Hide comment
@douglasmamilor

douglasmamilor Feb 20, 2017

@Timer Sorry if this is newbie question but this change isn't reflected in the current npm package right?

@Timer Sorry if this is newbie question but this change isn't reflected in the current npm package right?

@gaearon

This comment has been minimized.

Show comment
Hide comment
@gaearon

gaearon Feb 20, 2017

Member

No, this is tagged as 0.10.0:

screen shot 2017-02-20 at 14 28 35

The last released version is 0.9.0 (you can check the releases page).

Member

gaearon commented Feb 20, 2017

No, this is tagged as 0.10.0:

screen shot 2017-02-20 at 14 28 35

The last released version is 0.9.0 (you can check the releases page).

@douglasmamilor

This comment has been minimized.

Show comment
Hide comment

@gaearon Got it! Thanks!

danielfigueiredo pushed a commit to danielfigueiredo/create-react-app that referenced this pull request Feb 22, 2017

Add support for dynamic import & disable require.ensure (#1538)
* Disable require.ensure

* Replace require.ensure with import

* Add babel plugin for parsing import()

* Get the default

* Upgrade babel-eslint to support dynamic import

* Fix dep

* Update deps

bondz added a commit to bondz/create-react-app that referenced this pull request Feb 24, 2017

Add support for dynamic import & disable require.ensure (#1538)
* Disable require.ensure

* Replace require.ensure with import

* Add babel plugin for parsing import()

* Get the default

* Upgrade babel-eslint to support dynamic import

* Fix dep

* Update deps

kst404 pushed a commit to kst404/e8e-react-scripts that referenced this pull request Mar 2, 2017

Add support for dynamic import & disable require.ensure (#1538)
* Disable require.ensure

* Replace require.ensure with import

* Add babel plugin for parsing import()

* Get the default

* Upgrade babel-eslint to support dynamic import

* Fix dep

* Update deps

SpaceK33z added a commit to CodeYellowBV/create-react-cy-app that referenced this pull request Mar 7, 2017

Add support for dynamic import & disable require.ensure (#1538)
* Disable require.ensure

* Replace require.ensure with import

* Add babel plugin for parsing import()

* Get the default

* Upgrade babel-eslint to support dynamic import

* Fix dep

* Update deps

# Conflicts:
#	package.json
#	packages/babel-preset-react-app/package.json
#	packages/babel-preset-react-cy-app/index.js
#	packages/react-cy-scripts/config/webpack.config.dev.js
#	packages/react-cy-scripts/config/webpack.config.prod.js
@gaearon

This comment has been minimized.

Show comment
Hide comment
@gaearon

gaearon May 16, 2017

Member

Please help beta test the new version that includes this change!
#2172

Member

gaearon commented May 16, 2017

Please help beta test the new version that includes this change!
#2172

bmson pushed a commit to zendesk/create-react-app that referenced this pull request Jun 23, 2017

Add support for dynamic import & disable require.ensure (#1538)
* Disable require.ensure

* Replace require.ensure with import

* Add babel plugin for parsing import()

* Get the default

* Upgrade babel-eslint to support dynamic import

* Fix dep

* Update deps
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment