mirror of
https://github.com/usebruno/bruno.git
synced 2024-11-07 08:34:15 +01:00
feat: package init for graphql-docs
This commit is contained in:
parent
c0e1bf6bc2
commit
9e64ea5439
@ -6,7 +6,8 @@
|
||||
"packages/bruno-electron",
|
||||
"packages/bruno-tauri",
|
||||
"packages/bruno-schema",
|
||||
"packages/bruno-testbench"
|
||||
"packages/bruno-testbench",
|
||||
"packages/bruno-graphql-docs"
|
||||
],
|
||||
"devDependencies": {
|
||||
"@faker-js/faker": "^7.6.0",
|
||||
|
22
packages/bruno-graphql-docs/.gitignore
vendored
Normal file
22
packages/bruno-graphql-docs/.gitignore
vendored
Normal file
@ -0,0 +1,22 @@
|
||||
# dependencies
|
||||
node_modules
|
||||
yarn.lock
|
||||
pnpm-lock.yaml
|
||||
package-lock.json
|
||||
.pnp
|
||||
.pnp.js
|
||||
|
||||
# testing
|
||||
coverage
|
||||
|
||||
# production
|
||||
dist
|
||||
|
||||
# misc
|
||||
.DS_Store
|
||||
*.pem
|
||||
|
||||
# debug
|
||||
npm-debug.log*
|
||||
yarn-debug.log*
|
||||
yarn-error.log*
|
21
packages/bruno-graphql-docs/package.json
Normal file
21
packages/bruno-graphql-docs/package.json
Normal file
@ -0,0 +1,21 @@
|
||||
{
|
||||
"name": "@usebruno/graphql-docs",
|
||||
"version": "0.1.0",
|
||||
"main": "dist/cjs/index.js",
|
||||
"module": "dist/esm/index.js",
|
||||
"scripts": {
|
||||
"build": "rollup -c"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@rollup/plugin-commonjs": "^23.0.2",
|
||||
"@rollup/plugin-node-resolve": "^15.0.1",
|
||||
"@rollup/plugin-typescript": "^9.0.2",
|
||||
"@types/react": "^18.0.25",
|
||||
"react": "^17.0.2",
|
||||
"rollup": "^2.79.1",
|
||||
"rollup-plugin-dts": "^5.0.0",
|
||||
"rollup-plugin-peer-deps-external": "^2.2.4",
|
||||
"rollup-plugin-terser": "^7.0.2",
|
||||
"typescript": "^4.8.4"
|
||||
}
|
||||
}
|
34
packages/bruno-graphql-docs/rollup.config.js
Normal file
34
packages/bruno-graphql-docs/rollup.config.js
Normal file
@ -0,0 +1,34 @@
|
||||
import resolve from "@rollup/plugin-node-resolve";
|
||||
import commonjs from "@rollup/plugin-commonjs";
|
||||
import typescript from "@rollup/plugin-typescript";
|
||||
import dts from "rollup-plugin-dts";
|
||||
import { terser } from "rollup-plugin-terser";
|
||||
import peerDepsExternal from 'rollup-plugin-peer-deps-external';
|
||||
|
||||
const packageJson = require("./package.json");
|
||||
|
||||
export default [
|
||||
{
|
||||
input: "src/index.ts",
|
||||
output: [
|
||||
{
|
||||
file: packageJson.main,
|
||||
format: "cjs",
|
||||
sourcemap: true,
|
||||
},
|
||||
{
|
||||
file: packageJson.module,
|
||||
format: "esm",
|
||||
sourcemap: true,
|
||||
},
|
||||
],
|
||||
plugins: [
|
||||
peerDepsExternal(),
|
||||
resolve(),
|
||||
commonjs(),
|
||||
typescript({ tsconfig: "./tsconfig.json" }),
|
||||
terser(),
|
||||
],
|
||||
external: ["react", "react-dom", "styled-components"]
|
||||
}
|
||||
];
|
9
packages/bruno-graphql-docs/src/GraphDocs.tsx
Normal file
9
packages/bruno-graphql-docs/src/GraphDocs.tsx
Normal file
@ -0,0 +1,9 @@
|
||||
import React from 'react';
|
||||
|
||||
class GraphDocs extends React.Component {
|
||||
render() {
|
||||
return "Graphql Docs Explorer"
|
||||
}
|
||||
}
|
||||
|
||||
export default GraphDocs;
|
5
packages/bruno-graphql-docs/src/index.ts
Normal file
5
packages/bruno-graphql-docs/src/index.ts
Normal file
@ -0,0 +1,5 @@
|
||||
import GraphDocs from "./GraphDocs";
|
||||
|
||||
export {
|
||||
GraphDocs
|
||||
}
|
22
packages/bruno-graphql-docs/tsconfig.json
Normal file
22
packages/bruno-graphql-docs/tsconfig.json
Normal file
@ -0,0 +1,22 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"esModuleInterop": true,
|
||||
"strict": true,
|
||||
"skipLibCheck": true,
|
||||
"jsx": "react",
|
||||
"module": "ESNext",
|
||||
"declaration": true,
|
||||
"declarationDir": "types",
|
||||
"sourceMap": true,
|
||||
"outDir": "dist",
|
||||
"moduleResolution": "node",
|
||||
"emitDeclarationOnly": true,
|
||||
"allowSyntheticDefaultImports": true,
|
||||
"forceConsistentCasingInFileNames": true
|
||||
},
|
||||
"exclude": [
|
||||
"dist",
|
||||
"node_modules",
|
||||
"src/**/*.test.tsx"
|
||||
],
|
||||
}
|
Loading…
Reference in New Issue
Block a user