vite-plugin-gql
TypeScript icon, indicating that this package has built-in type declarations

0.1.4 • Public • Published

vite-plugin-gql

Similar to graphql-tag/loader, but for vite. This is an attempt to take an existing plugin vite-plugin-graphql, update it to match the latest code in graphql-tag's loader, and get it to work properly in a vite project. It does seem to compile the graphql files correct but then at runtime will load them all individually, which is very slow, and fail to execute them properly. PRs against the project are very welcome, and I would very happily give the name of the project over to someone who can make this work properly with their own plugin.

Installation

npm i vite-plugin-gql
yarn add vite-plugin-gql
pnpm i vite-plugin-gql

Usage

const gqlPlugin = require('vite-plugin-gql');

const config = {
  plugins: [gqlPlugin],
};

Now all the files ends with .gql or .graphql will be handled by vite-plugin-gql.

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 0.1.4
    1
    • latest

Version History

Package Sidebar

Install

npm i vite-plugin-gql

Weekly Downloads

5

Version

0.1.4

License

MIT

Unpacked Size

36.1 kB

Total Files

8

Last publish

Collaborators

  • aubreyholland