Skip to content

Conversation

@shimks
Copy link
Contributor

@shimks shimks commented Apr 26, 2018

Checklist

  • npm test passes on your machine
  • New tests added or existing tests modified to cover all changes
  • Code conforms with the style guide
  • API Documentation in code was updated
  • Documentation in /docs/site was updated
  • Affected artifact templates in packages/cli were updated
  • Affected example projects in examples/* were updated

// License text available at https://opensource.org/licenses/MIT

import {JsonDefinition} from '@loopback/repository-json-schema';
import {JSONSchema6} from '@loopback/repository-json-schema';
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

import {JSONSchema6 as JSONSchema}

@shimks shimks force-pushed the replace-json-schema branch from dbac19f to 21289f5 Compare April 26, 2018 18:57
export * from './build-schema';

import {JSONSchema6} from 'json-schema';
export {JSONSchema6};
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

JSONSchema as we talked about here?

@raymondfeng
Copy link
Contributor

lodash.includes dependency is not used. Please remove it.


return result;
}

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

TSDocs here perhaps?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added

@shimks
Copy link
Contributor Author

shimks commented Apr 26, 2018

@raymondfeng It is used in https://github.com/strongloop/loopback-next/pull/1286/files#diff-432476dd2d984e441d8b4e0af39a39beR68. We could just use includes on Array.prototype if you want to cut down the packages we use.

@shimks shimks force-pushed the replace-json-schema branch from 21289f5 to 6b04f99 Compare April 26, 2018 19:15
* Helper function used to interpret boolean values as JSON Schemas.
* See http://json-schema.org/draft-06/json-schema-release-notes.html
* @param jsonOrBool converts boolean values into their representative JSON Schemas
*/
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice! nitpick: missing @returns

@shimks shimks force-pushed the replace-json-schema branch from 6b04f99 to e8a1e51 Compare April 26, 2018 19:25
@raymondfeng
Copy link
Contributor

@raymondfeng It is used in https://github.com/strongloop/loopback-next/pull/1286/files#diff-432476dd2d984e441d8b4e0af39a39beR68. We could just use includes on Array.prototype if you want to cut down the packages we use.

We should use Array.prototype.includes

@shimks shimks force-pushed the replace-json-schema branch from e8a1e51 to 34607ea Compare April 26, 2018 20:24
@shimks shimks force-pushed the replace-json-schema branch from 34607ea to c8fc00e Compare April 26, 2018 20:26
@shimks shimks merged commit e9e6b12 into master Apr 26, 2018
@shimks shimks deleted the replace-json-schema branch April 26, 2018 20:58
Copy link
Member

@bajtos bajtos left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👏

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Replace type definition being imported by repository-json-schema

6 participants