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

Change exported library name to proper JS variable #86

Closed
jlongster opened this issue Feb 5, 2016 · 1 comment
Closed

Change exported library name to proper JS variable #86

jlongster opened this issue Feb 5, 2016 · 1 comment

Comments

@jlongster
Copy link

Line https://github.com/bvaughn/react-virtualized/blob/master/webpack.config.dist.js#L14 in webpack makes it so that if you include this as a <script> tag on a page, it sets it to window["react-virtualized"] which is strange. I would expect it to be window.ReactVirtualized, so that it exposes a ReactVirtualized global without forcing a referencing through the window object.

@bvaughn
Copy link
Owner

bvaughn commented Feb 5, 2016

Hey @jlongster. Seems like a good suggestion. Since this is a backwards incompatible change- I'm going to consider this for the upcoming v5 release. (I kind of doubt anyone's using the library as window["react-virtualized"] but... just in case, I don't want to break them in a minor point release.)

I've actually been considering support Common JS only for the upcoming release. Although I guess I could also include a <script>-friendly dist file as well.

PS. Perfect timing on your Twitter post about hidden messages with script tags. I was just briefly thrown by the seemingly cutoff email summary I got for this issue.

@bvaughn bvaughn added the v5 label Feb 5, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants