Use of allowSyntheticDefaultImports flag in tsconfig.json
YagoLopez opened this issue · comments
Reading README.md it says:
Moving files over to TypeScript
[...]
We'll immediately get a few errors, but they're easy enough to fix. The changes will include:
Replace import React, {Component} from 'react'; with import * as React from 'react';
I am using React+Typescript, and activating the flag allowSyntheticDefaultsImports
in tsconfig.json
solves this issue. Now you can use import React, {Component} from 'react'
without modificate the code.
I was wondering if it is worth I send a pull request to modify README.md. Thanks