The issue is that it can trigger ENAMETOOLONG error if the key is larger than the OS can handle, raising:
ERROR [nitro] [cache] Cache write error. ENAMETOOLONG: name too long, open '/home/stf/projects/laast/laast-io-monorepo/apps/frontend/.nuxt/cache/nuxt/icon/ph_bankduotone_calculatorduotone_calendarblankduotone_calendardotsduotone_chartpiesliceduotone_chatduotone_gearduotone_lifebuoyduotone_packageduotone_sealcheckduotone_squarehalfduotone_stackduotone_storefrontduotone_timerduotone_usersduotone_wrenchduotone.json'
at async open (node:internal/fs/promises:639:25)
at async Object.writeFile (node:internal/fs/promises:1219:14)
at async Object.setItem (/home/stf/projects/laast/laast-io-monorepo/node_modules/.pnpm/unstorage@1.12.0_ioredis@5.4.1/node_modules/unstorage/dist/index.mjs:205:7)
Using multiple icons of the same provider will grow cache key length as described here: https://github.com/nuxt/icon/blob/7cb5ade2057699c2fb132afc29353e45f629490b/src/runtime/server/api.ts#L72-L76
The issue is that it can trigger ENAMETOOLONG error if the key is larger than the OS can handle, raising:
Maybe using ohash can be a solution?