Skip to content

Commit

Permalink
fix examples
Browse files Browse the repository at this point in the history
  • Loading branch information
ianstormtaylor committed Nov 29, 2017
1 parent 6ba079a commit 4c9a91e
Show file tree
Hide file tree
Showing 7 changed files with 7 additions and 12 deletions.
1 change: 1 addition & 0 deletions Readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,7 @@ Superstruct's API is very flexible, allowing it to be used for a variety of use
- [Default Values](./examples/default-values.js)
- [Composing Structs](./examples/composing-structs.js)
- [Throwing Errors](./examples/throwing-errors.js)
- [Returning Errors](./examples/returning-errors.js)
- [Custom Errors](./examples/custom-errors.js)


Expand Down
3 changes: 1 addition & 2 deletions examples/basic-validation.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
/* eslint-disable no-console */

import struct from '..'
import { struct } from 'superstruct'

// Define a struct to validate with.
const User = struct({
Expand Down
3 changes: 1 addition & 2 deletions examples/composing-structs.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
/* eslint-disable no-console */

import struct from '..'
import { struct } from 'superstruct'

// Define a `user` struct.
const User = struct({
Expand Down
3 changes: 1 addition & 2 deletions examples/custom-errors.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
/* eslint-disable no-console */

import struct from '..'
import { struct } from 'superstruct'

// Define a struct to validate with.
const User = struct({
Expand Down
3 changes: 1 addition & 2 deletions examples/custom-types.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
/* eslint-disable no-console */

import { superstruct } from '..'
import { superstruct } from 'superstruct'
import isEmail from 'is-email'
import isUuid from 'is-uuid'
import isUrl from 'is-url'
Expand Down
3 changes: 1 addition & 2 deletions examples/default-values.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
/* eslint-disable no-console */

import struct from '..'
import { struct } from 'superstruct'

// Define an auto-incrementing unique id.
let uid = 1
Expand Down
3 changes: 1 addition & 2 deletions examples/throwing-errors.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
/* eslint-disable no-console */

import struct from '..'
import { struct } from 'superstruct'

// Define a struct to validate with.
const User = struct({
Expand Down

0 comments on commit 4c9a91e

Please sign in to comment.