File tree Expand file tree Collapse file tree 1 file changed +9
-7
lines changed
Expand file tree Collapse file tree 1 file changed +9
-7
lines changed Original file line number Diff line number Diff line change 22
33## 需要知道更多信息
44
5- https://github.com/tailwindlabs/tailwindcss/blob/437579d3f010a98ae4b824a7d5694486119fbdcd/crates/oxide/src/lib.rs#L108
5+
66
77现在的情况, ` tailwindcss ` 在从文件/内容中提取出 ` Candidate ` 的时候,是仅仅提取出一些字符串的信息。
88
@@ -21,15 +21,15 @@ interface Candidate {
2121
2222这样我们就能进行精确的修改,比如:
2323
24- ``` jsx title="before"
25- const className = ` gap-y-4 bg-zinc-800/30` ;
24+ ``` diff filename="diff"
25+ // before
26+ - const className = `gap-y-4 bg-zinc-800/30`;
27+ // after
28+ + const className = `a b`;
2629```
2730
28- ``` js title="after"
29- const className = ` a b` ;
30- ```
3131
32- 不然现在去进行修改的话,只能所有的文件都去应用 整个 ` Candidates ` (` Set<string> ` ) 进行替换来修改,这往往会导致很多的误伤。
32+ 不然现在去进行修改的话,只能所有的文件都去应用 整个 ` Candidates ` \ (` Set<string> ` \ ) 进行替换来修改,这往往会导致很多的误伤。
3333
3434而有了这个,我们只需要找到对应的文件,修改它的 ` start ` 和 ` end ` 对应的节点就能达到目的了
3535
@@ -43,6 +43,8 @@ const className = `a b`;
4343
4444## Tailwindcss v4
4545
46+ https://github.com/tailwindlabs/tailwindcss/blob/437579d3f010a98ae4b824a7d5694486119fbdcd/crates/oxide/src/lib.rs#L108
47+
4648``` rs
4749 pub fn scan (& mut self ) -> Vec <String > {
4850 init_tracing ();
You can’t perform that action at this time.
0 commit comments