Created
December 18, 2018 03:46
-
-
Save ethagnawl/1e1bdbbfcdeda0fb264fa81d7bd5bef0 to your computer and use it in GitHub Desktop.
gatsby-plugin-elm-demo
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from "react"; | |
import ScenesComponentElm from "../components/ScenesElm"; | |
export default ({ data }) => { | |
let elmScenes = ["hello", "wut", "goodbye"]; | |
return ( | |
<ScenesComponentElm scenes={elmScenes} /> | |
) | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const Elm = require("react-elm-components"); | |
const React = require("react"); | |
const ElmApplication = require("./src/Main.elm"); | |
const ScenesComponentElm = ({scenes}) => ( | |
<Elm | |
flags={{ scenes: scenes }} | |
src={ElmApplication.Elm.Main} | |
/> | |
); | |
export default ScenesComponentElm; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment