Comments (10)
@dkozickis After doing some reading, it would seem that one of the other implications is that Babel 7 doesn't actually do any type-checking of Typescript code, it just transpiles it down to Javascript. If you want type-checking, you still have to run tsc
.
from create-react-app-typescript.
@hassankhan https://blogs.msdn.microsoft.com/typescript/2018/08/27/typescript-and-babel-7/
from create-react-app-typescript.
I believe the correct CRA version is 2.1. Also one more difference to add could be that in CRA 2.1 you can't use <Type>expression
to cast, only expression as Type
. Which is a super minor thing as you can't use it in TSX anyway so it only applies to TS files which I believe are usually in a minority in React based TS projects.
from create-react-app-typescript.
Thanks @tomashubelbauermicrosoft, I've updated the table above. Do you think its worth mentioning the differences from here too?
from create-react-app-typescript.
Decorators won' bet supported until CRA 2.1.1: facebook/create-react-app#5642
EDIT: Now fixed and released as CRA 2.1.1.
from create-react-app-typescript.
What are the implications of using Babel vs tsc for transpilation?
from create-react-app-typescript.
@doxxx Namespaces and casting
from create-react-app-typescript.
I think we should include babel-loader for typescript files as well because of the super handy babel-plugin-macros
. Or perhaps do it opt-in somehow.
from create-react-app-typescript.
Just tried out CRA 2.1.0
.
Looks like linting is based on eslint. And there is too much mismatch between vscode dev environment and linting errors. There is no eslint config file created to customize anything. And I felt documentation was lacking wrt linting in general.
CRA-TS
does it perfectly for me. If the console shows an error, vscode shows it too.
from create-react-app-typescript.
@doxxx I thought I'd read that somewhere too, but can't seem to find any links 😕. If you could post one, that would be awesome 👍
from create-react-app-typescript.
Related Issues (20)
- Browserlist error
- CRA 2.0 HOT 31
- Include nodejs v8 for for Travis CI build
- Remove dependency on babel HOT 2
- Using jest-extended? HOT 1
- Husky hooks not working HOT 1
- Update webpack-dev-server HOT 10
- Source Maps don't work for `js` or `jsx` files in live dev mode.
- Version 4.0.8: Internet Explorer no working anymore HOT 2
- Build process is almost 20 minutes long HOT 1
- postcss support? HOT 1
- Why is Jest's version hard coded to "20.0.4"? HOT 1
- Jest doesn't work when I add lint-staged
- Maintenance
- Tslint rules are barriers to entry HOT 2
- [Help] Compatibility IE + Firefox old versions problems
- Are 4.X.X versions are legit? HOT 1
- Jest doesn't resolve absolute paths from tsconfig HOT 1
- npm start dont work on freeBSD
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from create-react-app-typescript.