script-lab-2017
script-lab-2017 copied to clipboard
Offer React support in snippets
https://medium.freecodecamp.com/yes-react-is-taking-over-front-end-development-the-question-is-why-40837af8ab76
Some thoughts from Bhargav, in email form on 4/4/2017:
I have been thinking about it before we go about doing that we need to verify that Monaco editor supports the tsx syntax. It's actually fairly easy to implement it as long as the developer adheres to some constraints:
- You'll not be able to the import syntax and must assume react is included as a global variable.
- You'll be restricted to using only typescript.
- You'll not be able to use any react library that cannot be loaded via a cdn. This may involve redux, fabric react and others
So a lot of testing and verification will be in order post the implementation issues.
For the Monaco editor portion (supporting the tsx syntax): There is a tracking bug on the Monaco side, https://github.com/Microsoft/monaco-editor/issues/264