fregante / iphone-inline-video

📱 Make videos playable inline on the iPhone (prevents automatic fullscreen)
https://npm.im/iphone-inline-video
MIT License
2.05k stars 300 forks source link

Uncaught SyntaxError: Unexpected token import in iphone-inline-video when transferred to codeigniter framework #110

Closed windchime18 closed 7 years ago

windchime18 commented 7 years ago

How come when I deploy it on my codeigniter framework it doesn't work? It displays an error in javascript on my console.

Uncaught SyntaxError: Unexpected token import index.js:1

import {frameIntervalometer} from 'intervalometer'; import preventEvent from '../../assets/lib/prevent-event'; import proxyProperty from '../../assets/lib/proxy-property'; import proxyEvent from '../../assets/lib/proxy-event'; import dispatchEventAsync from '../../assets/lib/dispatch-event-async';

fregante commented 7 years ago

Are you using browserify/webpack? If not, you need to use the files in the DIST folder, like https://github.com/bfred-it/iphone-inline-video/blob/master/dist/iphone-inline-video.min.js

windchime18 commented 7 years ago

thanks. it worked :)