Skip to content

Commit

Permalink
Spruce codemirror example
Browse files Browse the repository at this point in the history
  • Loading branch information
aboodman committed Dec 6, 2023
1 parent 3a524ac commit 78e4ae0
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 21 deletions.
2 changes: 1 addition & 1 deletion examples/codemirror/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Reflect + YJS Example</title>
<title>Reflect + YJS + CodeMirror Example</title>
</head>
<body>
<div id="root"></div>
Expand Down
17 changes: 7 additions & 10 deletions examples/codemirror/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,26 +13,23 @@
"preview": "vite preview",
"watch": "concurrently --kill-others 'npx reflect dev --silence-startup-message' 'VITE_REFLECT_URL=http://127.0.0.1:8080/ npm run dev'"
},
"dependencies": {
"@codemirror/lang-javascript": "^6.2.1",
"@rocicorp/reflect-yjs": "0.0.1",
"react-codemirror2": "^7.3.0",
"y-codemirror": "^3.0.1",
"@rocicorp/reflect": "^0.38.202311200859"
},
"devDependencies": {
"@codemirror/lang-javascript": "^6.2.1",
"@rocicorp/eslint-config": "^0.5.1",
"@rocicorp/prettier-config": "^0.2.0",
"@rocicorp/reflect-yjs": "0.0.1",
"@rocicorp/reflect": "^0.38.202311200859",
"@types/react": "^18.2.38",
"@types/react-dom": "^18.2.17",
"@types/react": "^18.2.38",
"@vitejs/plugin-react": "^4.2.0",
"concurrently": "^8.2.2",
"nanoid": "^5.0.3",
"react": "^18.2.0",
"react-codemirror2": "^7.3.0",
"react-dom": "^18.2.0",
"react": "^18.2.0",
"typescript": "^5.3.2",
"vite": "^5.0.2"
"vite": "^5.0.2",
"y-codemirror": "^3.0.1"
},
"eslintConfig": {
"extends": "@rocicorp/eslint-config"
Expand Down
4 changes: 2 additions & 2 deletions examples/codemirror/src/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ import './index.css';
import styles from './index.module.css';
import {
Provider,
mutators,
mutators as yjsMutators,
Mutators,
} from '@rocicorp/reflect-yjs';
import {UserInfo, randUserInfo} from './user-info.js';

Expand All @@ -32,7 +32,7 @@ const reflect = new Reflect({
});

type ReflectCodeMirrorProps = {
reflect: Reflect<Mutators>;
reflect: Reflect<typeof mutators>;
name: string;
userInfo: UserInfo;
};
Expand Down
19 changes: 11 additions & 8 deletions package-lock.json

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

0 comments on commit 78e4ae0

Please sign in to comment.