Skip to content

Commit

Permalink
fix build
Browse files Browse the repository at this point in the history
  • Loading branch information
dimaMachina committed Aug 20, 2024
1 parent f75b224 commit 47906be
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions packages/graphiql-plugin-explorer/vite.config.mts
Original file line number Diff line number Diff line change
Expand Up @@ -57,14 +57,14 @@ function htmlPlugin(): PluginOption {
const require = createRequire(import.meta.url);

const graphiqlPath = require
.resolve('graphiql')
.replace('/dist/index.js', '');
.resolve('graphiql/package.json')
.replace('/package.json', '');

const htmlForVite = `<link rel="stylesheet" href="${graphiqlPath}/src/style.css" />
<script type="module">
import React from 'react';
import ReactDOM from 'react-dom/client';
import GraphiQL from '${graphiqlPath}/src/cdn.ts';
import GraphiQL from '${graphiqlPath}/src/cdn';
import * as GraphiQLPluginExplorer from './src';
Object.assign(globalThis, { React, ReactDOM, GraphiQL, GraphiQLPluginExplorer });
Expand Down

0 comments on commit 47906be

Please sign in to comment.