Skip to content
This repository has been archived by the owner on Oct 12, 2022. It is now read-only.

Reference to jquery remains in the jsx sample. Sample not working #157

Open
mikevbaker opened this issue Aug 28, 2019 · 2 comments
Open

Comments

@mikevbaker
Copy link

mikevbaker commented Aug 28, 2019

The references to jquery were removed in commit e190f5a.

A reference to jquery still remains in app.tsx and in require-config.js
app.tsx $ remains
ReactDOM.render(<Greetifier {...props} greeting={getRandomGreeting} />, $('#output').get(0));

configure-js
"jquery": ['/node_modules/jquery/dist/jquery']

I tried replacing $('#output') with document.getElementById('#output') but got an error "Target container is not a DOM element." I don't know where to go from here.

@mikevbaker
Copy link
Author

I figured it out. I forgot to remove the # from the id. The correct line would be this...

ReactDOM.render(<Greetifier {...props} greeting={getRandomGreeting} />, document.getElementById('output'));

@mikevbaker
Copy link
Author

I have changes done locally and will create PR whenever it's marked 'help wanted'.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant