chore: optimize SEO and fix golangci-lint issues

- Implement dynamic SEO meta tags and sitemap.xml for toolbox.pengzhan.dev
- Fix SPA title/meta refresh issue in layout.html
- Address golangci-lint findings:
  - Refactor switch-case for tool path and SVG token parsing
  - Replace math.Pow with direct multiplication for performance
  - Fix unhandled error returns and unused imports
  - Omit redundant type declarations
This commit is contained in:
2026-03-01 09:54:04 -08:00
parent c3d0dee806
commit 5c185da0a9
9 changed files with 657 additions and 229 deletions
+1 -1
View File
@@ -31,7 +31,7 @@ var IconCategories = map[string][]Icon{
{Name: "Trapezoid", Paths: []string{"M 300 200 L 724 200 L 924 800 L 100 800 Z"}},
{Name: "Hexagon", Paths: []string{"M 512 100 L 858 300 L 858 724 L 512 924 L 166 724 L 166 300 Z"}},
},
"fruits": {},
"fruits": {},
}
type SVG struct {