Skip to content

Commit

Permalink
Update tic-tac-toe React initialization
Browse files Browse the repository at this point in the history
  • Loading branch information
StorytellerCZ committed Sep 6, 2022
1 parent fd11247 commit c55b67e
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion README.md
Expand Up @@ -7,7 +7,7 @@
- Repository: [meteor/examples/tic-tac-toe](./tic-tac-toe)
- Why: To show that we can even build multiplayer games with meteor.
- Stack: Meteor and React
- Last Updated At: Aug/25/2022
- Last Updated At: Sep/06/2022
- Meteor Version: 2.7.3

#### Simple Tasks
Expand Down
6 changes: 3 additions & 3 deletions tic-tac-toe/client/main.jsx
@@ -1,9 +1,9 @@
import React from 'react';
import { Meteor } from 'meteor/meteor';
import { createRoot } from 'react-dom/client';
import { App } from '/imports/ui/App';
import { render } from 'react-dom'

Meteor.startup(() => {
const root = createRoot(document.getElementById('react-target'))
root.render(<App/>);
const root = document.getElementById('react-target')
render(<App />, root)
});
6 changes: 3 additions & 3 deletions tic-tac-toe/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion tic-tac-toe/package.json
Expand Up @@ -8,7 +8,7 @@
"visualize": "meteor --production --extra-packages bundle-visualizer"
},
"dependencies": {
"@babel/runtime": "^7.18.9",
"@babel/runtime": "^7.19.0",
"meteor-node-stubs": "^1.2.5",
"react": "^18.2.0",
"react-dom": "^18.2.0",
Expand Down

0 comments on commit c55b67e

Please sign in to comment.