Subscribe on changes!

SyntaxError: missing = in const declaration

avatar
Oct 12th 2020

UPDATE

Bug with for...in (for(const e in s)) I'm manual replace to for(let e in s) App worked


Version

3.0.0

Reproduction link

https://codesandbox.io/s/gracious-ives-19ruu

Steps to reproduce

  1. create first vue app with vue-cli (vue create hello-world)
  2. yarn serve (nodejs 12.18.4)
  3. Firefox 48a2

What is expected?

I'm will get a Hello world app

What is actually happening?

I'm get a error

SyntaxError: missing = in const declaration chunk-vendor.js line 296:19


Firefox 48 can download from here: http://archive.mozilla.org/pub/firefox/nightly/2016/06/2016-06-05-00-40-13-mozilla-aurora/

With vuejs 2.x it's work in firefox 48

avatar
Oct 12th 2020

https://caniuse.com/?search=const

Hi @unbyte,

with vue@2, no any problem with FF 48a2 But with vue@3, I don't understand why.


I want to build KaiOS (FF 48a2) application with vue@3. Maybe I can't do that with vue@3

avatar
Oct 12th 2020

Slightly related: I can’t seem to find any statement with regards to browser support/compatibility in the Vue.js 3 documentation. Without it, how can I know whether Firefox 48 is supposed to be supported?

avatar
Oct 12th 2020

Any bug in here?

if(s)for(const e in s)t[e]=s[e]
avatar
Oct 12th 2020

with vue@2, no any problem with FF 48a2 But with vue@3, I don't understand why.

sorry but I refer to this only for reference and to indicate that const itself is supported in Firefox 48

Any bug in here?

if(s)for(const e in s)t[e]=s[e]

is this fragment at line 296:19? but const in for-in and for-of loops is supported by Firefox 48 as caniuse shows

avatar
Dec 31st 2020

This seems to be a bug in Firefox itself, see https://stackoverflow.com/questions/39044803/syntaxerror-missing-in-const-declaration-firefox-50 and https://bugzilla.mozilla.org/show_bug.cgi?id=1101653 for further reference. I'm currently experiencing the same issue while creating a Svelte 3.0 App with Rollup for KaiOS. The developer build throws exactly the same error, the production build runs without any issues. I don't know about Vue, but maybe creating a production build also resolves your issue.

avatar
Jan 6th 2021

@FloppyNotFound i'm make a build production for run in KaiOS

avatar
Mar 5th 2021

I have the same problem

avatar
May 20th 2021

I have the same problem! Serving a production build didn't help in my case.

avatar
May 21st 2021

Solved it. I was testing my website in Firefox 48. Because I wanted my website to work in kaiOS browsers which run on firefox 48. The packages I was using were written using ES6 syntax and firefox 48 doesn't support that. So I had to add those packages to a transpileDependencies array in my vue.config.js and it was working perfectly. https://cli.vuejs.org/core-plugins/babel.html#configuration

avatar
Mar 14th 2023

I'm closing this issue because: