Я видел первый, который использовался в традиционной веб -разработке, но я увидел второй в просто реагирование. < /p>
import React from 'react';
import './MyComponent.css';
function MyComponent() {
return (
This is my component.
);
}
export default MyComponent;
< /code>
или: < /p>
import React from 'react';
import style from './MyComponent.css';
function MyComponent() {
return (
This is my component.
);
}
export default MyComponent;
Подробнее здесь: https://stackoverflow.com/questions/795 ... -just-impo
Мобильная версия