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

Adding videos to the project #6

Closed
mparker11 opened this issue Dec 30, 2017 · 2 comments
Closed

Adding videos to the project #6

mparker11 opened this issue Dec 30, 2017 · 2 comments

Comments

@mparker11
Copy link

Has anyone ever tried adding a local video file to this project? I get a blank div even though the url is present in the dev tools, and that url is playable when pasting in a browser manually. I haven't changed any webpack files and I'm simply calling the video in my main App.js file like so:

import React, { Component } from 'react';
import { curious } from '@curi/react';
import AttractLoop from '../../assets/videos/video.mp4';

class App extends Component {
    render() {
        return (
            <div className="app-container">
                <div className="attract-loop">
                    <video width="1080" height="1920">
                        <source src={ AttractLoop } type="video/mp4" />
                    </video>
                </div>
            </div>
        );
    }
}

export default curious(App);
@naviapis
Copy link
Member

NW.js does not support mp4 by default.
https://github.com/nwjs/nw.js/wiki/Using-MP3-%26-MP4-%28H.264%29-using-the--video--%26--audio--tags.
http://docs.nwjs.io/en/latest/For%20Developers/Enable%20Proprietary%20Codecs/
Please wait for a while because I am looking for a countermeasure.

@mparker11
Copy link
Author

Thanks for this! I would not have figured this out for a good while (as it had already been a few days before I raised the issue).

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

2 participants