contentlayerdev / contentlayer

Contentlayer turns your content into data - making it super easy to import MD(X) and CMS content in your app
https://www.contentlayer.dev
MIT License
3.26k stars 200 forks source link

Support Vite #179

Open schickling opened 2 years ago

schickling commented 2 years ago

Add your vote for Vite support by clicking the 👍 emoji below.

Notes:

benbender commented 2 years ago

@schickling s/Astro/Vite/ ;)

o-az commented 2 years ago

please 🙏

schickling commented 2 years ago

I appreciate everyone looking forward to this integration but please use the 👍 button instead of leaving +1 comments.

Even more helpful could be if someone wants to take a stab at prototyping/building a Vite <> Contentlayer integration. The more explored this topic already is, the easier it will be for an "official version" to be release. 🚀

phothinmg commented 1 year ago

please

Chalkin commented 11 months ago

Voting for vite. (With support for Vue.js and Nuxt 3)

grunklejp commented 10 months ago

I started messing around with this today and found a really easy way to configure Vite that folks can use before there is an "Official Vite Plugin". This also works well with a vite vue.js project.

//vite.config.ts
import { defineConfig } from "vite";
import react from "@vitejs/plugin-react";
import { watch } from "vite-plugin-watch";

export default defineConfig({
  plugins: [
    react(),
    watch({
      pattern: "./posts/**/*.{mdx,md}",
      command: "contentlayer build",
    }),
  ],
  resolve: {
    alias: {
      "contentlayer/generated": "/.contentlayer/generated",
    },
  },
});
m6io commented 8 months ago

Yas vite pls

longechipi commented 3 months ago

Yes please

meabhipatel commented 1 month ago

Yes, Vite