Manually merge from 'pre-kjol' into 'master'
This commit is contained in:
@@ -119,6 +119,15 @@ func generateFAIcons() error {
|
||||
}
|
||||
b.WriteString("};\n")
|
||||
|
||||
// Skip the write when content is unchanged so the file's mtime doesn't
|
||||
// advance on every SPA source edit — the dev watcher treats any mtime bump
|
||||
// as a real change and hot-reloads Icons.tsx (the nearest HMR boundary that
|
||||
// imports this file), which is wasteful when nothing about the icon set
|
||||
// actually changed.
|
||||
if existing, err := os.ReadFile(faOutPath()); err == nil && string(existing) == b.String() {
|
||||
return nil
|
||||
}
|
||||
|
||||
if err := os.MkdirAll(filepath.Dir(faOutPath()), 0755); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user