Skip to content

Commit

Permalink
tidying up
Browse files Browse the repository at this point in the history
  • Loading branch information
newhouse committed Jul 27, 2022
1 parent 2c6e63b commit 52d0adc
Show file tree
Hide file tree
Showing 6 changed files with 5 additions and 7 deletions.
2 changes: 1 addition & 1 deletion config-example.yml
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ introspection:
spectaqlDirective:
# Boolean indicating whether to enable and process the @spectaql directive
#
# Eefault: true
# Default: true
enable: true

# String indicating the name to use for the SpectaQL directive
Expand Down
2 changes: 0 additions & 2 deletions examples/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@ introspection:

spectaqlDirective:
enable: true
# directiveName: 'spectaqlll'
# optionsTypeName: 'SpectaQLOption'

extensions:
graphqlScalarExamples: true
Expand Down
3 changes: 3 additions & 0 deletions examples/data/schema.gql
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,9 @@ type MyType implements MyInterface {
requiredArrayField: [String]!

doubleRequiredArrayField: [String!]!

"This field will not show up thanks to the @spectaql directive options"
fieldThatWillNotShowUp: String! @spectaql(options: [{key: "undocumented", value: "true" }])
}

"This is a type that should probably be undocumented. Metadata will indicate this should be hidden"
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
"pub:dry-run": "yarn prepare && npm publish --dry-run",
"test": "mocha --config ./test/mocha-config.js",
"test:watch": "nodemon -x 'yarn clean-build && yarn test'",
"develop": "nodemon -x 'yarn clean-build && node --inspect=0.0.0.0:9223 bin/spectaql' -D",
"develop": "nodemon -x 'yarn clean-build && node bin/spectaql' -D",
"build:site": "node bin/spectaql",
"build:example": "yarn build:site --target-dir ./examples/output ./examples/config.yml",
"prettify": "prettier 'src/**/*.js' 'bin/**/*.js' 'test/**/*.js'",
Expand Down
1 change: 0 additions & 1 deletion src/spectaql/directive.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ const OPTION_TO_CONVERTER_FN = {
documented: (val) => val === true || val === 'true',
example: (val) => JSON.parse(val),
examples: (vals) => JSON.parse(vals),
info: (val) => val,
}

export function generateSpectaqlSdl({
Expand Down
2 changes: 0 additions & 2 deletions src/spectaql/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,6 @@ function run(opts) {

const { introspectionResponse, graphQLSchema } = buildSchemas(opts)

// console.log(JSON.stringify(introspectionResponse))

// Figure out what data arranger to use...the default one, or the one from the theme
const customDataArrangerExists = ['data/index.js', 'data.js'].some(
(pathSuffix) => {
Expand Down

0 comments on commit 52d0adc

Please sign in to comment.