React and Inkle integration #768
-
Can ink be used in React by appending the files in the JSX section of App.js? I tried implementing componentDidMount() class App extends React.Component { const story = document.createElement("story"); const main = document.createElement("main"); document.body.appendChild(script); } The mechanics of the ink story are simple, and don't require any Redux state changes, so I was not wanting to implement those ... but I will if I have to. This code just returns a blank page with no story, just the headline (which is in the App.js anyway, so the three .js files story.js, main.js and ink.js just aren't doing their stuff. Any thoughts? EDIT: I also tried .useEffect, which also silently appended without loading any of the scripts. react-helmet did not work, either. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
just used Redux |
Beta Was this translation helpful? Give feedback.
just used Redux