flarelabs-net / vite-plugin-cloudflare

12 stars 1 forks source link

Cloudflare built-ins in `optimizeDeps.exclude` are untested #51

Closed dario-piotrowicz closed 2 weeks ago

dario-piotrowicz commented 2 weeks ago

In optimizeDeps.exclude we add the Cloudflare builtin modules: https://github.com/flarelabs-net/vite-plugin-cloudflare/blob/4bdc0a8d0d5dc0961fbb8417a524855780eaae7a/packages/vite-plugin-cloudflare/src/cloudflare-environment.ts#L147

However commenting out the line doesn't cause any of the tests to fail, so either:

We should have a look and either remove the values if they are unnecessary or add tests for them.

dario-piotrowicz commented 2 weeks ago

oh... it just slipped my mind, I did add those earlier today 🤦

The issue was that they were triggering a warning: https://github.com/flarelabs-net/vite-plugin-cloudflare/issues/47 (without actually breaking any functionality)

I think we should be able to somewhat easily add some tests to make sure that the warning is not shown.