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

Universal configuration on files in the /static folder? #1471

Closed
czzarr opened this issue Mar 21, 2017 · 2 comments
Closed

Universal configuration on files in the /static folder? #1471

czzarr opened this issue Mar 21, 2017 · 2 comments

Comments

@czzarr
Copy link

czzarr commented Mar 21, 2017

Hi,

I have followed the universal configuration example (https://github.com/zeit/next.js/tree/master/examples/with-universal-configuration) and it works well but it seems not for a js file in the /static folder.
How can I make this work?

The reason I have to serve this js file is because I'm using the google javascript api for authentication and as it maintains state by itself I chose to have it completely separate from my react app.

Thanks

@sergiodxa
Copy link
Contributor

Next.js doesn't touch your static files, you should do it manually with Babel or using a custom Webpack configuration.

@arunoda
Copy link
Contributor

arunoda commented Mar 21, 2017

As @sergiodxa mentioned we don't do that for static files.
If you wanna a export some keys, try to set it to the window by writing a custom document.

@arunoda arunoda closed this as completed Mar 21, 2017
@lock lock bot locked as resolved and limited conversation to collaborators May 11, 2018
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