5 ms·
I just started a new project. We were using TypeScript for some important client side communication libraries which had no UI. This new project has a lot of UI.
by euroclydon 11y ago
I just started a new project. We were using TypeScript for some important client side communication libraries which had no UI. This new project has a lot of UI. I chose Babel since it has built-in support for JSX -- that seemed like a bigger win than type safety.
- tinganho 11y agoTypeScript also have JSX support. It's in master right now.
- merpnderp 11y agoYou just made my day with this!!!
- jbrantly 11y agoShameless plug but hopefully helpful: http://www.jbrantly.com/typescript-and-jsx/ http://www.jbrantly.com/typescript-and-jsx/ And more: http://blog.mgechev.com/2015/07/05/using-jsx-react-with-typescript/ http://blog.mgechev.com/2015/07/05/using-jsx-react-with-type... http://basarat.gitbooks.io/typescript/content/docs/jsx/tsx.html http://basarat.gitbooks.io/typescript/content/docs/jsx/tsx.h...
- Ciantic 11y agoAnd you can use it today with unofficial "Not" TypeScript https://github.com/TypeStrong/ntypescript https://github.com/TypeStrong/ntypescript or simply using atom-typescript extension for Atom which has it installed.
- euroclydon 11y agoThanks... I found the closed issue: https://github.com/Microsoft/TypeScript/issues/3203 https://github.com/Microsoft/TypeScript/issues/3203 And some docs from the contributor's branch: https://github.com/RyanCavanaugh/jsx-intro https://github.com/RyanCavanaugh/jsx-intro Nothing yet mentioned in the master's markdown. Do you know when the next TypeScript release is planned for which will include this?
- jbrantly 11y agoTypeScript 1.6 will have this. Unknown release date but there is this: https://twitter.com/jntrnr/status/620607598903996417 https://twitter.com/jntrnr/status/620607598903996417
- rpwverheij 11y agooh man, this makes me so happy. Two projects I really really enjoy are finally coming together without any hacks. I knew it could only be a matter of time - and I had it working with a little React.jsx(`<component />`) hack, but still, having the TS team implement it natively just makes it feel right. thanks to everyone involved! ... Can't wait till webstorm will fully support this with component property intellisense and everything. woot!
- smrtinsert 11y agoI was using babel, but the compiler seems to crash every chance it gets. It should be able to handle simple editing without anywhere near a crash.
- freeqaz 11y agoI like to use r-dom to get around JSX. I feel like, with JSX, I tend to copy-paste code or not refactor something into it's own method. With r-dom, it forces you to realize you're writing Javascript (not HTML) and try to write DRY code. https://www.npmjs.com/package/r-dom https://www.npmjs.com/package/r-dom