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

Error: btoa is not defined #101

Open
jbool24 opened this issue Oct 2, 2020 · 3 comments
Open

Error: btoa is not defined #101

jbool24 opened this issue Oct 2, 2020 · 3 comments

Comments

@jbool24
Copy link

jbool24 commented Oct 2, 2020

I keep getting this error at build time when creating static versions of this Vue app. Not sure what this function/variable is meant to reference.

ReferenceError: btoa is not defined
3:47:47 PM:     at addStyle (/opt/build/repo/node_modules/eagle.js/dist/eagle.cjs.js:444:7)
3:47:47 PM:     at /opt/build/repo/node_modules/eagle.js/dist/eagle.cjs.js:424:12
3:47:47 PM:     at a.__vue_inject_styles__ (/opt/build/repo/node_modules/eagle.js/dist/eagle.cjs.js:482:5)
3:47:47 PM:     at a.hook (/opt/build/repo/node_modules/eagle.js/dist/eagle.cjs.js:397:13)
3:47:47 PM:     at Ft (/opt/build/repo/node_modules/vue/dist/vue.runtime.common.prod.js:6:11191)
3:47:47 PM:     at Ze (/opt/build/repo/node_modules/vue/dist/vue.runtime.common.prod.js:6:25133)
3:47:47 PM:     at a.e._init (/opt/build/repo/node_modules/vue/dist/vue.runtime.common.prod.js:6:32564)
3:47:47 PM:     at new a (/opt/build/repo/node_modules/vue/dist/vue.runtime.common.prod.js:6:30340)
3:47:47 PM:     at Vi (/opt/build/repo/node_modules/vue-server-renderer/build.prod.js:1:66341)
3:47:47 PM:     at io (/opt/build/repo/node_modules/vue-server-renderer/build.prod.js:1:70571)
3:47:47 PM:     at ro (/opt/build/repo/node_modules/vue-server-renderer/build.prod.js:1:70244)
3:47:47 PM:     at _t.eo [as renderNode] (/opt/build/repo/node_modules/vue-server-renderer/build.prod.js:1:67491)
3:47:47 PM:     at _t.next (/opt/build/repo/node_modules/vue-server-renderer/build.prod.js:1:20507)
3:47:47 PM:     at n (/opt/build/repo/node_modules/vue-server-renderer/build.prod.js:1:18719)
3:47:47 PM:     at /opt/build/repo/node_modules/vue-server-renderer/build.prod.js:1:68602
3:47:47 PM:     at eo (/opt/build/repo/node_modules/vue-server-renderer/build.prod.js:1:68610)
3:47:47 PM: Done in 35.13s.
@esoterra
Copy link

I was able to find the root error.
It's an issue with vue-component-compiler itself that prevents SSR from working correctly.
vuejs/vue-component-compiler#88

@aesdotjs
Copy link

aesdotjs commented Jun 21, 2021

If you encounter this error, or static site generation issues i made a fork that fixes this and enables SSR with eagle.js
https://github.com/aesdotjs/eagle.js

Its litteraly 2 lines and 1 package addition (the rest of the commits was to have the dist in git)
aesdotjs@967e583

@benamar
Copy link

benamar commented Sep 27, 2021

@aesdotjs Do you plan to make a pull request?

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

4 participants