[x] import types for existing libraries used including prosemirror
[x] migrate all .js files in /app/javascript/components to .tsx (Editor.js left)
[x] replace most any types in types.ts
[ ] migrate Editor.js to Editor.tsx
[ ] migrate all .js files in /app/javascript/components/editor-config to .ts
@dennyluan I think we should merge this and close off the typescript migration project. I could work on this for another month (or longer), but I don't think that is the best use of our resources. I'd like for us to move onto cleaning up our redux stuff.
I think the current PR gives enough of a blueprint for us to follow.
@alexkrolick if you come across this and have thoughts or suggestions, would love to hear them!
My recommendation is we create .tsx files for new react components with the intention of no implicit anys and strict null checks. All javascript files should be .ts moving forward. For existing code, we fix and resolve as it conveniently overlaps with our product priorities.
This PR is a second attempt at https://github.com/jellypbc/poster/pull/372.
yarn add typescript
tsconfig.json
types.ts
/app/javascript/components/types.ts
yarn lint
to pass@types/prosemirror-commands
@types/prosemirror-model
/app/javascript/components
to .tsx (Editor.js left)/app/javascript/components/editor-config
to .ts@dennyluan I think we should merge this and close off the typescript migration project. I could work on this for another month (or longer), but I don't think that is the best use of our resources. I'd like for us to move onto cleaning up our redux stuff.
I think the current PR gives enough of a blueprint for us to follow.
@alexkrolick if you come across this and have thoughts or suggestions, would love to hear them!
My recommendation is we create
.tsx
files for new react components with the intention of no implicit anys and strict null checks. All javascript files should be.ts
moving forward. For existing code, we fix and resolve as it conveniently overlaps with our product priorities.