Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

code split use import('path/to/modue').then(m=>{}) doesn't work. #1954

Closed
ray0324 opened this issue Apr 9, 2017 · 3 comments
Closed

code split use import('path/to/modue').then(m=>{}) doesn't work. #1954

ray0324 opened this issue Apr 9, 2017 · 3 comments

Comments

@ray0324
Copy link

ray0324 commented Apr 9, 2017

I can‘t split my app withimport('path/to/modue').then(m=>{})
and the Doc of create-react-app about ’code-spliting‘ has no content

@n3tr
Copy link
Contributor

n3tr commented Apr 9, 2017

Support for dynamic import has been added to master (#1538) but it has not been released yet 😅

For 0.9.x please use require.ensure('path/to/module, (r) => {}) for code splitting.

@gaearon
Copy link
Contributor

gaearon commented Apr 9, 2017

Yea, please use require.ensure for now. We'll add the doc and support for dynamic imports in 0.10.

@gaearon gaearon closed this as completed Apr 9, 2017
@gaearon
Copy link
Contributor

gaearon commented May 16, 2017

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

@lock lock bot locked and limited conversation to collaborators Jan 21, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants