我正在使用 nextjs、typescript 和 scss。在 global.scss 上有 *(asterisk selector) 將填充和邊距設置為零(0),但它不起作用
* {
box-sizing: border-box;
padding: 0;
margin: 0;
}
import "../styles/globals.scss";
import type { AppProps } from "next/app";
import "antd/dist/antd.css";
function MyApp({ Component, pageProps }: AppProps) {
return <Component {...pageProps} />;
}
export default MyApp;
嘗試 :
* {
box-sizing: border-box !important;
padding: 0 !important;
margin: 0 !important;
}
Este artigo é coletado da Internet.
Se houver alguma infração, entre em [email protected] Delete.
deixe-me dizer algumas palavras