diff --git a/.idea/workspace.xml b/.idea/workspace.xml
index e860f82..f1c4d81 100644
--- a/.idea/workspace.xml
+++ b/.idea/workspace.xml
@@ -1,20 +1,27 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
@@ -31,10 +38,11 @@
+
-
+
@@ -108,8 +116,21 @@
-
+
+
+
+
+
+
+
+
+ 1590646177438
+
+
+
+ 1590646177438
+
@@ -132,76 +153,45 @@
-
-
-
-
-
+
-
-
+
-
-
+
-
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
-
-
+
+
-
+
\ No newline at end of file
diff --git a/config-overrides.js b/config-overrides.js
index bf03497..26bf67d 100644
--- a/config-overrides.js
+++ b/config-overrides.js
@@ -23,7 +23,7 @@ module.exports = override(
}),
addWebpackModuleRule({
test: /\.scss$/,
- loaders: ['style-loader', 'css-loader', 'sass-loader', {
+ loaders: ['style-loader', 'css-loader?modules', 'sass-loader', {
loader: 'sass-resources-loader',
options: {
resources: ['./src/assets/scss/_index.scss']
diff --git a/src/index.js b/src/index.js
index 58f853b..27cba85 100644
--- a/src/index.js
+++ b/src/index.js
@@ -1,8 +1,5 @@
-import React from 'react';
-import ReactDOM from 'react-dom';
-import App from '@/views/App.js';
-
-ReactDOM.render(
- ,
- document.getElementById('root'));
+import React from "react";
+import ReactDOM from "react-dom";
+import App from "@/views/App.js";
+ReactDOM.render(, document.getElementById("root"));
diff --git a/src/ui/footer/footer.module.css b/src/ui/footer/footer.module.css
new file mode 100644
index 0000000..0e5bcdb
--- /dev/null
+++ b/src/ui/footer/footer.module.css
@@ -0,0 +1,3 @@
+.error {
+ background-color: red;
+}
\ No newline at end of file
diff --git a/src/ui/footer/index.js b/src/ui/footer/index.js
index 34b52e8..392f472 100644
--- a/src/ui/footer/index.js
+++ b/src/ui/footer/index.js
@@ -1,15 +1,17 @@
-import React, {Component} from "react"
-
+import React, { Component } from "react";
+import styles from "./footer.module.css"; // 使用 CSS Modules 的方式引入
+const classNames = require('classnames');
export default class Footer extends Component {
- constructor(props) {
- super(props);
- console.log("fuck")
- }
-
- render() {
- return (
-
gfhfg
- );
- }
+ constructor(props) {
+ super(props);
+ console.log("fuck");
+ }
+
+ render() {
+
+ var myClass = classNames(styles.error); // => 'foo bar'
+
+ return gfhfg
;
+ }
}
diff --git a/src/ui/header/index.js b/src/ui/header/index.js
new file mode 100644
index 0000000..9402e3d
--- /dev/null
+++ b/src/ui/header/index.js
@@ -0,0 +1,15 @@
+import React, {Component} from "react"
+
+
+export default class Footer extends Component {
+ constructor(props) {
+ super(props);
+ console.log("fuck")
+ }
+
+ render() {
+ return (
+ gfhfg
+ );
+ }
+}
diff --git a/src/views/App.js b/src/views/App.js
index 0e9a071..be78013 100644
--- a/src/views/App.js
+++ b/src/views/App.js
@@ -1,7 +1,9 @@
import React, {Fragment} from 'react';
import Footer from "@/ui/footer"
import {Input, List, Popconfirm} from 'antd';
-import "./App.scss"
+import apap from "./App.scss"
+
+console.log(apap);
const {Search} = Input;
@@ -38,7 +40,8 @@ export default class App extends React.Component {
return (
-
+ sad
+
this.setState({val: e.value})}
onSearch={this.onSearch}
/>
+ asdddddd
diff --git a/src/views/App.scss b/src/views/App.scss
index a95ce0b..75c2251 100644
--- a/src/views/App.scss
+++ b/src/views/App.scss
@@ -2,7 +2,13 @@
$todo: todolist;
.#{$todo}__input{
margin: 20px;
+ .test{
+ color: aqua;
+ }
}
.#{$todo}__item{
margin: 20px;
+ >.test{
+ color: aqua;
+ }
}