KSubedi / transliteration-input-tools

Unofficial client to Google's Transliteration Backend
MIT License
41 stars 12 forks source link

How can I use this in create-react-app #18

Closed biomathcode closed 3 years ago

biomathcode commented 3 years ago

I don't know webpack, But i followed your instructions on Client Side. To copy paste the javascript bundle into the Public file of create react app. And then i tried to use it but didn't work.

Can you make a npm package//(or may be you already have but i can't find it). ?

Error i got

Uncaught TypeError: Cannot read property 'addEventListener' of null at t.registerListeners (transliteration-input.bundle.js:1) at new t (transliteration-input.bundle.js:1) at new <anonymous> (transliteration-input.bundle.js:1) at r (transliteration-input.bundle.js:1) at (index):51

milantarami commented 3 years ago

you are trying to add an event listener on null. make sure you are adding an event listener to DOM element

Horopter commented 2 years ago

@biomathcode Do you have a react demo I could use as a reference point? Preferably as a jsfiddle?

biomathcode commented 2 years ago

@Horopter I used https://github.com/burhanuday/react-transliterate instead. Hope it helps

Horopter commented 2 years ago

That's really cool. Thanks @biomathcode.