Reputation: 31
Getting an error on this
<body onload="setupZoom();" style={{background:url("/img/bg.jpg") repeat-x #fff}}>
Babel is complaining either about regular expressions when I take the double quotes out, or an unexpected token ,
.
{ SyntaxError: /Users/robert/multiDomainCMS/views/winwinhost.com/index.jsx: Unexpected token, expected "," (49:72)
47 | <title>Unlimited Windows Web Hosting, Unlimited Reseller Hosting, Web hosting & Domain Names</title>
48 | </head>
> 49 | <body onload="setupZoom();" style={{background:url("/img/bg.jpg") repeat-x #fff}}>
| ^
50 |
51 | <div class="d_container">
52 | <div class="d_header">
at Object.raise (/Users/robert/multiDomainCMS/node_modules/@babel/parser/lib/index.js:3831:17)
at Object.unexpected (/Users/robert/multiDomainCMS/node_modules/@babel/parser/lib/index.js:5143:16)
at Object.expect (/Users/robert/multiDomainCMS/node_modules/@babel/parser/lib/index.js:5135:28)
at Object.parseObj (/Users/robert/multiDomainCMS/node_modules/@babel/parser/lib/index.js:6600:14)
at Object.parseExprAtom (/Users/robert/multiDomainCMS/node_modules/@babel/parser/lib/index.js:6229:21)
at Object.parseExprAtom (/Users/robert/multiDomainCMS/node_modules/@babel/parser/lib/index.js:3552:20)
at Object.parseExprSubscripts (/Users/robert/multiDomainCMS/node_modules/@babel/parser/lib/index.js:5862:23)
at Object.parseMaybeUnary (/Users/robert/multiDomainCMS/node_modules/@babel/parser/lib/index.js:5842:21)
at Object.parseExprOps (/Users/robert/multiDomainCMS/node_modules/@babel/parser/lib/index.js:5729:23)
at Object.parseMaybeConditional (/Users/robert/multiDomainCMS/node_modules/@babel/parser/lib/index.js:5702:23)
pos: 3141,
loc: Position { line: 49, column: 72 },
code: 'BABEL_PARSE_ERROR' }
I would really appreciate some help, because I have no clue: What am I doing wrong?
Upvotes: 0
Views: 652
Reputation: 2560
You forgot to add single quotes to the background
value <body onload="setupZoom();" style={{background: 'url("/img/bg.jpg") repeat-x #fff'}}>
Upvotes: 1