robbestad / react-iframe

Simple solution for using iframes in React
ISC License
434 stars 79 forks source link

Import error #10

Closed ericmei closed 6 years ago

ericmei commented 7 years ago

Importing react-iframe produces an error

Examples: Testing on https://runkit.com/npm/react-iframe

Produces two syntax errors: SyntaxError: Unexpected token import A stack trace for this error could not be retrieved because stack was already called.


Importing locally and attempting to run a file with the import using either

var Iframe =  require('react-iframe');
import Iframe from 'react-iframe';

produces the following error:

index.js:1 Uncaught SyntaxError: Unexpected token import

reginaldwhite commented 7 years ago

It appears to me that the dependencies aren't being installed properly. When I compare my package.json file, the only change is "react-iframe": "^1.0.5",

DavitVosk commented 7 years ago

The same issue here. It causes Internal Server Error 500. After the 'import' is deleted, the application works fine. Something is wrong with the package

kostya9116 commented 7 years ago

The same issue here, it isn't working

arpu commented 7 years ago

ERROR in bundle.js from UglifyJs SyntaxError: Unexpected token: name (React) [./~/react-iframe/index.js:1,0]

sunlee-newyork commented 7 years ago

Same here

droyuki commented 7 years ago

same issue

michelaquino commented 7 years ago

Same here

hebertthome commented 7 years ago

Same here

joeandrews commented 7 years ago

+1

robbestad commented 7 years ago

Sorry about that. Should be fixed in v1.0.7

2017-06-02 17:55 GMT+02:00 Joe Andrews notifications@github.com:

+1

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/svenanders/react-iframe/issues/10#issuecomment-305830288, or mute the thread https://github.com/notifications/unsubscribe-auth/ABfQp67yC_B7k_USjPH7dFhKXtVTDMeWks5sADBqgaJpZM4NIHMy .

-- Mvh, Sven Anders Robbestad http://www.robbestad.com http://twitter.com/#!/svenardocom

brandonerick1224 commented 7 years ago

It doesn't work in Safari

robbestad commented 7 years ago

Can you provide your version number? It works in 10.1.1 (12603.2.4)

robbestad commented 6 years ago

Closing for now as I think it's okay. Let me know if you still have problems!