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

[q] getting an error with Server-side-rendering setup #137

Open
vladp opened this issue May 23, 2018 · 2 comments
Open

[q] getting an error with Server-side-rendering setup #137

vladp opened this issue May 23, 2018 · 2 comments

Comments

@vladp
Copy link

vladp commented May 23, 2018

hello,
getting error

\ssr-aft\node_modules\split.js\split.js:13
var global = window;
             ^

this is because the import statements 'aggressively' evaluate globals.

I plan to use the library within React didMount (meaning that by the time the library is needed, I will be in the browser). Because selective/dynamic imports are not yet an available feature of javascript -- these kinds of things create problems.

So wanted to check with user community of the Split.js on what they do to get this working with SSR

thank you

@nathancahill
Copy link
Owner

What bundler are you using to include Split.js?

@SomethingSexy
Copy link

I am having this issue with Webpack and TypeScript but I haven't looked into it in much detail yet.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants