使用motion.js库在create-react-app中创建的项目中的样式优先级/层次结构是什么?

问题描述 投票:0回答:0

我正在使用create-react-app开发一个单页应用程序,大多数所有组件都是静态的,而其他一些则是有状态的。 为它们设置样式,我使用的是css-in-js插件motion.js。 我在类声明之外的const中创建样式,然后在组件内部进行引用。 我的问题是,在看起来像这样的文件树中:

./ public / index.html src / index.js , /components /(the smaller components)如果每个较小的组件和组件也都使用库进行了样式设置)。 层次结构是什么,它如何继承?

css reactjs styles operator-precedence emotion
© www.soinside.com 2019 - 2024. All rights reserved.