in production will code be readable or minified?

so in dev mode currently i can read each file as i wrote it in my browser but once in production will it be more obsfucated and not readable like this?
9 Replies
kapa.ai
kapa.ai4d ago
Hi @WiFi Plug. I'm kapa.ai, your friendly support bot. I will try to answer your question by searching through the knowledge base. :wave: ---------------------- In production, your Nuxt application's code will be minified and much less readable compared to development mode. During development, files are served in a readable format to aid debugging, but when you run the production build, Nuxt (using Vite or Webpack) minifies and optimizes your code. This process removes whitespace, shortens variable names, and generally obfuscates the code, making it difficult to read or reverse-engineer in the browser. This is confirmed in the documentation, which states that the production output is "minified and removed from any Node.js modules (except polyfills)" and is optimized for deployment, not for readability Server-Side Rendering. Additionally, the Nuxt configuration for Webpack shows that code minimization is enabled by default in production Nuxt Config: optimization. So, yes—once in production, your code will be minified and not easily readable like it is in development. ---------------------- Note: you can ask me a follow up question by @ mentioning me again :speech_balloon: ----------------------
kapa.ai
kapa.ai4d ago
<@679734274840330384> Kapa.ai is still learning and improving, please let me know how I did by reacting below.
WiFi Plug
WiFi PlugOP4d ago
@kapa.ai currently im just testing locally but once im ready to test with it deployed somewhere or for production what are the most popular places to host the site?
kapa.ai
kapa.ai4d ago
Let me check the knowledge base for you again. One moment! :books: ---------------------- Some of the most popular places to host a Nuxt site, according to the official documentation, include: - Vercel: Nuxt Content projects can be deployed to Vercel with zero configuration. You can use the Vercel dashboard or run npx vercel deploy to get started. The module automatically detects the Vercel environment and configures itself accordingly Deploy to Vercel. - Netlify: Similar to Vercel, you can deploy your Nuxt Content app to Netlify by connecting your git repository. Make sure to set the Node.js version to 20.x or higher in the site configuration Deploy to Netlify. - Cloudflare Pages: Nuxt Content supports deployment to Cloudflare Pages, which is optimized for edge hosting Cloudflare Pages. - NuxtHub: A platform built on top of Cloudflare services, offering a streamlined experience for deploying Nuxt apps with database, KV, file storage, and caching on the edge NuxtHub. - Node.js Server: You can deploy your Nuxt app on any Node.js hosting provider by running the built server output (.output/server/index.mjsDeployment. - Static Hosting: If you use static site generation, you can upload the generated files to any static hosting service Static Hosting. These platforms are well-supported and require minimal configuration for Nuxt projects. The choice depends on your needs (serverless, edge, static, or traditional Node.js server). ---------------------- Note: you can ask me a follow up question by @ mentioning me again :speech_balloon: ----------------------
kapa.ai
kapa.ai4d ago
<@679734274840330384> Kapa.ai is still learning and improving, please let me know how I did by reacting below.
WiFi Plug
WiFi PlugOP4d ago
@kapa.ai so im using supabase for auth and database so what might be the best place to host it for auto scaling is nuxt optimised for anything specific or what's the most popular choices in that case>
kapa.ai
kapa.ai4d ago
Let me check the knowledge base for you again. One moment! :books: ---------------------- If you are using Supabase for authentication and database, and want auto-scaling for your Nuxt app, the most popular and well-supported hosting choices are Vercel, Netlify, Cloudflare Pages, and NuxtHub. These platforms are optimized for serverless and edge deployments, which provide automatic scaling and are widely used in the Nuxt ecosystem. Nuxt is not tied to a single hosting provider and is designed for universal deployment, supporting all of these platforms with minimal configuration. The official documentation highlights Vercel, Netlify, Cloudflare, and NuxtHub as first-class options for deploying Nuxt applications, especially when using serverless or edge hosting for auto-scaling needs Deployment Serverless Hosting. You can confidently choose any of these providers for your Nuxt + Supabase stack. The choice often comes down to your preference, pricing, and any specific features you need (such as edge functions or global CDN). All of them are popular and well-supported in the Nuxt community. ---------------------- Note: you can ask me a follow up question by @ mentioning me again :speech_balloon: ----------------------
kapa.ai
kapa.ai4d ago
<@679734274840330384> Kapa.ai is still learning and improving, please let me know how I did by reacting below.
johntanzer
johntanzer3d ago
It will be a bit more obfstruted. However at the end of the day all data is there. You can just test by running npm run build

Did you find this page helpful?