diff --git a/.changeset/config.json b/.changeset/config.json index d54bb16..3593b4a 100644 --- a/.changeset/config.json +++ b/.changeset/config.json @@ -1,10 +1,13 @@ { - "$schema": "https://unpkg.com/@changesets/config@1.3.0/schema.json", + "$schema": "https://unpkg.com/@changesets/config@1.6.0/schema.json", "changelog": "@changesets/cli/changelog", "commit": false, "linked": [], "access": "public", "baseBranch": "master", "updateInternalDependencies": "patch", - "ignore": [] + "ignore": [], + "___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH": { + "useCalculatedVersionForSnapshots": true + } } diff --git a/.changeset/sharp-yaks-flash.md b/.changeset/sharp-yaks-flash.md new file mode 100644 index 0000000..4c8d7f8 --- /dev/null +++ b/.changeset/sharp-yaks-flash.md @@ -0,0 +1,5 @@ +--- +'xstate-codegen': minor +--- + +The implementation has been rewritten to be based on TypeScript compiler APIs which enhances the possibility of static analysis. diff --git a/.github/workflows/snapshot-release.yml b/.github/workflows/snapshot-release.yml new file mode 100644 index 0000000..ca10d84 --- /dev/null +++ b/.github/workflows/snapshot-release.yml @@ -0,0 +1,29 @@ +name: Snapshot Release + +on: pull_request + +jobs: + release: + runs-on: ubuntu-latest + steps: + - name: Checkout repo + uses: actions/checkout@v2 + + - name: Setup node + uses: actions/setup-node@v2 + with: + node-version: 12.x + + - name: Install dependencies + run: yarn + + - name: Prepare artifacts + run: yarn build + + - name: Release a snapshot + run: | + yarn changeset version --snapshot pr${{ github.event.pull_request.number }} + yarn changeset publish --tag pr${{ github.event.pull_request.number }} + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + NPM_TOKEN: ${{ secrets.NPM_TOKEN }} diff --git a/package.json b/package.json index 7b25b4e..807a96c 100644 --- a/package.json +++ b/package.json @@ -14,9 +14,12 @@ "packages/*" ], "scripts": { - "x": "yarn workspace xstate-codegen" + "x": "yarn workspace xstate-codegen", + "build": "npm run build --prefix packages/xstate-compiled", + "changeset": "changeset" }, "devDependencies": { - "ts-node":"9.0.0" + "@changesets/cli": "^2.16.0", + "ts-node": "9.0.0" } } diff --git a/packages/xstate-compiled/.npmignore b/packages/xstate-compiled/.npmignore index 5a0017c..a83a645 100644 --- a/packages/xstate-compiled/.npmignore +++ b/packages/xstate-compiled/.npmignore @@ -1,5 +1,4 @@ bin/__tests__ -bin/fake_node_modules examples coverage -node_modules \ No newline at end of file +node_modules diff --git a/packages/xstate-compiled/examples/anotherComplexMachine.machine.ts b/packages/xstate-compiled/examples/anotherComplexMachine.machine.ts index e326ef4..451525e 100644 --- a/packages/xstate-compiled/examples/anotherComplexMachine.machine.ts +++ b/packages/xstate-compiled/examples/anotherComplexMachine.machine.ts @@ -1,4 +1,4 @@ -import { Machine, send, assign } from '@xstate/compiled'; +import { createMachine, send, assign } from '@xstate/compiled'; type Attendee = { name: string; @@ -46,7 +46,7 @@ const assignAttendee = assign< }; }); -export const addViewingAttendeesMachine = Machine< +export const addViewingAttendeesMachine = createMachine< Context, Event, 'addViewingAttendees' diff --git a/packages/xstate-compiled/examples/chooseAction.machine.ts b/packages/xstate-compiled/examples/chooseAction.machine.ts deleted file mode 100644 index 852d606..0000000 --- a/packages/xstate-compiled/examples/chooseAction.machine.ts +++ /dev/null @@ -1,41 +0,0 @@ -import { Machine, actions } from '@xstate/compiled'; - -interface Context {} - -type Event = { type: 'SOME_EVENT' } | { type: 'ANOTHER_EVENT' }; - -/** - * An example machine using the `choose` action - */ -const machine = Machine({ - initial: 'idle', - states: { - idle: { - on: { - SOME_EVENT: { - actions: actions.choose([ - { cond: 'guardA', actions: ['actionA', 'actionB'] }, - { cond: 'guardB', actions: ['actionB'] }, - { actions: 'actionC' } - ]) - }, - ANOTHER_EVENT: { - cond: 'guardC', - actions: 'actionD', - } - }, - }, - }, -}, { - guards: { - guardA: (context, event) => false, - guardB: (context, event) => true, - guardC: (context, event) => true, - }, - actions: { - actionA: (context, event) => {}, - actionB: (context, event) => {}, - actionC: (context, event) => {}, - actionD: (context, event) => {}, - }, -}); \ No newline at end of file diff --git a/packages/xstate-compiled/examples/complexMachine.machine.ts b/packages/xstate-compiled/examples/complexMachine.machine.ts index ba259c1..80e917b 100644 --- a/packages/xstate-compiled/examples/complexMachine.machine.ts +++ b/packages/xstate-compiled/examples/complexMachine.machine.ts @@ -1,8 +1,13 @@ -import { assign, Machine, send, StateWithMatches } from '@xstate/compiled'; +import { + assign, + createMachine, + send, + StateWithMatches, +} from '@xstate/compiled'; type GetDemoMatterportViewingSubscription = {}; -export const complexMachineMachine = Machine< +export const complexMachineMachine = createMachine< ComplexMachineContext, ComplexMachineEvent, 'complexMachine' @@ -38,7 +43,7 @@ export const complexMachineMachine = Machine< ], }, errored: { - onEntry: send('REPORT_NO_PERMISSION_TO_VIEW'), + entry: send('REPORT_NO_PERMISSION_TO_VIEW'), }, isLoggedInAsAUser: { entry: 'startDataStream', @@ -94,7 +99,7 @@ export const complexMachineMachine = Machine< }, }, errored: { - onEntry: send('REPORT_NO_PERMISSION_TO_VIEW'), + entry: send('REPORT_NO_PERMISSION_TO_VIEW'), }, checksComplete: { type: 'final', @@ -103,7 +108,7 @@ export const complexMachineMachine = Machine< onDone: 'awaitingFirstPacketOfData', }, awaitingFirstPacketOfData: { - onEntry: 'startDataStream', + entry: 'startDataStream', on: { RECEIVE_DATA: [ { @@ -421,7 +426,7 @@ export const complexMachineMachine = Machine< on: { JOIN_CALL: 'requestingTwilioAudioOptions', }, - onEntry: 'reportHasNotJoinedCall', + entry: 'reportHasNotJoinedCall', }, requestingTwilioAudioOptions: { invoke: { @@ -470,7 +475,7 @@ export const complexMachineMachine = Machine< }, inCall: { type: 'parallel', - onEntry: 'reportHasJoinedCall', + entry: 'reportHasJoinedCall', states: { callOptionsModal: { initial: 'closed', @@ -512,7 +517,7 @@ export const complexMachineMachine = Machine< ], }, noVideo: { - onEntry: ['reportHostIsNotSharingVideo'], + entry: ['reportHostIsNotSharingVideo'], on: { TURN_ON_VIDEO: { cond: 'isHost', @@ -534,8 +539,8 @@ export const complexMachineMachine = Machine< }, }, video: { - onEntry: ['reportHostIsSharingVideo'], - onExit: ['reportHostIsNotSharingVideo'], + entry: ['reportHostIsSharingVideo'], + exit: ['reportHostIsNotSharingVideo'], on: { HIDE_VIDEO: { target: 'noVideo', @@ -560,14 +565,14 @@ export const complexMachineMachine = Machine< ], }, muted: { - onEntry: 'ensureMicrophoneMuted', + entry: 'ensureMicrophoneMuted', on: { TOGGLE_MUTE: 'unmuted', UNMUTE: 'unmuted', }, }, unmuted: { - onEntry: 'ensureMicrophoneUnmuted', + entry: 'ensureMicrophoneUnmuted', on: { TOGGLE_MUTE: 'muted', MUTE: 'muted', @@ -578,7 +583,7 @@ export const complexMachineMachine = Machine< }, }, callErrored: { - onEntry: 'reportHasNotJoinedCall', + entry: 'reportHasNotJoinedCall', type: 'final', }, }, diff --git a/packages/xstate-compiled/examples/createMachineOptions.machine.ts b/packages/xstate-compiled/examples/createMachineOptions.machine.ts deleted file mode 100644 index 8a1e3a0..0000000 --- a/packages/xstate-compiled/examples/createMachineOptions.machine.ts +++ /dev/null @@ -1,68 +0,0 @@ -import { createMachine, interpret } from '@xstate/compiled'; -import { useMachine } from '@xstate/compiled/react'; - -interface Context {} - -type Event = { type: 'MAKE_FETCH' }; - -/** - * Ensures that optional parameters register as non-required - * when passed in as a second param - */ -const machine = createMachine( - { - initial: 'idle', - states: { - idle: { - entry: ['requiredAction', 'nonRequiredAction'], - invoke: [ - { - src: 'requiredService', - onDone: [ - { - cond: 'requiredCond', - }, - { - cond: 'nonRequiredCond', - }, - ], - }, - { - src: 'nonRequiredService', - }, - ], - activities: ['requiredActivity', 'nonRequiredActivity'], - }, - }, - }, - { - actions: { - nonRequiredAction: () => {}, - }, - services: { - nonRequiredService: async () => {}, - }, - activities: { - nonRequiredActivity: () => {}, - }, - guards: { - nonRequiredCond: () => false, - }, - }, -); - -const useOptions = () => - useMachine(machine, { - actions: { - requiredAction: () => {}, - }, - services: { - requiredService: async () => {}, - }, - activities: { - requiredActivity: () => {}, - }, - guards: { - requiredCond: () => true, - }, - }); diff --git a/packages/xstate-compiled/examples/fetchMachine-nullishCoalesce.machine.ts b/packages/xstate-compiled/examples/fetchMachine-nullishCoalesce.machine.ts index 2653324..075f19d 100644 --- a/packages/xstate-compiled/examples/fetchMachine-nullishCoalesce.machine.ts +++ b/packages/xstate-compiled/examples/fetchMachine-nullishCoalesce.machine.ts @@ -1,4 +1,4 @@ -import { Machine, interpret } from '@xstate/compiled'; +import { createMachine, interpret } from '@xstate/compiled'; type Data = { yeah: boolean; @@ -13,7 +13,7 @@ type Event = | { type: 'CANCEL' } | { type: 'done.invoke.makeFetch'; data: Data }; -const machine = Machine({ +const machine = createMachine({ initial: 'idle', states: { idle: { diff --git a/packages/xstate-compiled/examples/fetchMachine-optionalActions.machine.ts b/packages/xstate-compiled/examples/fetchMachine-optionalActions.machine.ts index 5b42602..ecd21f4 100644 --- a/packages/xstate-compiled/examples/fetchMachine-optionalActions.machine.ts +++ b/packages/xstate-compiled/examples/fetchMachine-optionalActions.machine.ts @@ -1,4 +1,4 @@ -import { Machine, interpret } from '@xstate/compiled'; +import { createMachine } from '@xstate/compiled'; import { useMachine } from '@xstate/compiled/react'; type Data = { @@ -14,7 +14,7 @@ type Event = | { type: 'CANCEL' } | { type: 'done.invoke.makeFetch'; data: Data }; -const machine = Machine( +const machine = createMachine( { initial: 'idle', states: { diff --git a/packages/xstate-compiled/examples/fetchMachine-optionalServices.machine.ts b/packages/xstate-compiled/examples/fetchMachine-optionalServices.machine.ts index d206577..6e45231 100644 --- a/packages/xstate-compiled/examples/fetchMachine-optionalServices.machine.ts +++ b/packages/xstate-compiled/examples/fetchMachine-optionalServices.machine.ts @@ -1,4 +1,4 @@ -import { Machine, interpret } from '@xstate/compiled'; +import { createMachine } from '@xstate/compiled'; import { useMachine } from '@xstate/compiled/react'; type Data = { @@ -14,7 +14,7 @@ type Event = | { type: 'CANCEL' } | { type: 'done.invoke.makeFetch'; data: Data }; -const machine = Machine( +const machine = createMachine( { initial: 'idle', states: { diff --git a/packages/xstate-compiled/examples/fetchMachine.machine.ts b/packages/xstate-compiled/examples/fetchMachine.machine.ts index cc3fb4c..4004ebb 100644 --- a/packages/xstate-compiled/examples/fetchMachine.machine.ts +++ b/packages/xstate-compiled/examples/fetchMachine.machine.ts @@ -1,4 +1,4 @@ -import { Machine, interpret } from '@xstate/compiled'; +import { createMachine, interpret } from '@xstate/compiled'; type Data = { yeah: boolean; @@ -13,7 +13,7 @@ type Event = | { type: 'CANCEL' } | { type: 'done.invoke.makeFetch'; data: Data }; -const machine = Machine({ +const machine = createMachine({ initial: 'idle', states: { idle: { diff --git a/packages/xstate-compiled/examples/matt-fail-1.machine.ts b/packages/xstate-compiled/examples/matt-fail-1.machine.ts new file mode 100644 index 0000000..59f36c5 --- /dev/null +++ b/packages/xstate-compiled/examples/matt-fail-1.machine.ts @@ -0,0 +1,242 @@ +import { createMachine, send, assign } from '@xstate/compiled'; + +export type AddUserParams = { + name: string; + email: string; + username: string; + role: 'admin' | 'agent'; + profilePhoto?: string; + phoneNumber?: string; + whatsappNumber?: string; + biography?: string; +}; + +interface Context { + createParams?: AddUserParams; + updateParams?: AddUserParams; + usernameCheckCache: Record; + username?: string; +} + +export type Event = + | { type: 'SUBMIT_CREATE'; params: AddUserParams } + | { type: 'SUBMIT_UPDATE'; params: AddUserParams } + | { type: 'CANCEL' } + | { + type: 'REPORT_ERROR'; + } + | { type: 'REPORT_USERNAME_CHANGED'; username: string } + | { type: 'REPORT_RESET_PASSWORD' } + | { + type: 'done.invoke.checkIfUsernameIsUnique'; + data: { + isUnique: boolean; + }; + }; + +export const addUserMachine = createMachine( + { + id: 'addUserMachine', + context: { + usernameCheckCache: {}, + }, + on: { + REPORT_USERNAME_CHANGED: { + cond: 'usernameIsNotEmpty', + target: 'checkingIfIsInEditMode', + actions: [ + assign((context, event) => { + return { + username: event.username, + }; + }), + ], + }, + REPORT_RESET_PASSWORD: { + target: 'resettingPassword', + }, + }, + initial: 'idle', + states: { + idle: { + on: { + CANCEL: { actions: 'goBackToUsersPage' }, + SUBMIT_CREATE: { + target: 'creating', + cond: 'isUsernameValid', + actions: assign((context, event) => ({ + createParams: event.params, + })), + }, + SUBMIT_UPDATE: { + target: 'updating', + actions: assign((context, event) => ({ + updateParams: event.params, + })), + }, + }, + }, + checkingIfIsInEditMode: { + always: [ + { + target: 'idle', + cond: 'isInEditMode', + }, + { target: 'checkingUsernameUniqueness' }, + ], + }, + checkingUsernameUniqueness: { + initial: 'checkingIfWeHaveItInCache', + states: { + checkingIfWeHaveItInCache: { + always: [ + { + cond: 'isInCache', + target: 'complete', + }, + { + target: 'throttlingBeforeCheck', + }, + ], + }, + throttlingBeforeCheck: { + after: { + 800: 'checkingWithApi', + }, + }, + checkingWithApi: { + invoke: { + src: 'checkIfUsernameIsUnique', + onDone: { + target: 'complete', + actions: 'assignUsernameResultToCache', + }, + onError: { + target: 'complete', + }, + }, + }, + complete: { + type: 'final', + }, + }, + onDone: 'idle', + }, + resettingPassword: { + invoke: { + src: 'resetUserPassword', + onDone: { + target: 'idle', + actions: 'showSuccessfullyResetPasswordToast', + }, + onError: { + actions: 'showResetPasswordErroredToast', + target: 'idle', + }, + }, + }, + updating: { + initial: 'checking', + onDone: { target: 'complete', actions: 'reportUpdateSuccessViaToast' }, + on: { + REPORT_ERROR: 'idle', + }, + states: { + checking: { + always: [ + { + cond: 'hasChangedWhetherUserIsAdmin', + target: 'updatingUserAccount', + }, + { + target: 'updatingUserEntity', + }, + ], + }, + updatingUserAccount: { + invoke: { + src: 'updateUserAccount', + onDone: { + target: 'updatingUserEntity', + }, + onError: { + actions: [send('REPORT_ERROR'), 'reportErrorViaToast'], + }, + }, + }, + updatingUserEntity: { + invoke: { + src: 'updateUser', + onDone: { target: 'complete' }, + onError: { + actions: [send('REPORT_ERROR'), 'reportErrorViaToast'], + }, + }, + }, + complete: { + type: 'final', + }, + }, + }, + creating: { + initial: 'creatingUserInCognito', + on: { + REPORT_ERROR: 'idle', + }, + onDone: 'complete', + states: { + creatingUserInCognito: { + invoke: { + src: 'createUserInCognito', + onError: 'errored', + onDone: 'complete', + }, + }, + complete: { + type: 'final', + entry: 'reportCreateSuccessViaToast', + }, + errored: { + entry: [send('REPORT_ERROR'), 'reportErrorViaToast'], + }, + }, + }, + complete: { + entry: ['goBackToUsersPage'], + type: 'final', + }, + }, + }, + { + actions: { + assignUsernameResultToCache: assign((context, event) => { + if (!context.username) return {}; + return { + usernameCheckCache: { + ...context.usernameCheckCache, + [context.username]: event.data.isUnique, + }, + }; + }), + }, + guards: { + isInCache: (context) => { + if (!context.username) { + return false; + } + return ( + typeof context.usernameCheckCache[context.username] === 'boolean' + ); + }, + usernameIsNotEmpty: (context, event) => { + return Boolean(event.username); + }, + isUsernameValid: (context) => { + if (!context.username) { + return false; + } + return context.usernameCheckCache[context.username] === true; + }, + }, + }, +); diff --git a/packages/xstate-compiled/examples/matt-fail-2.machine.ts b/packages/xstate-compiled/examples/matt-fail-2.machine.ts new file mode 100644 index 0000000..001d709 --- /dev/null +++ b/packages/xstate-compiled/examples/matt-fail-2.machine.ts @@ -0,0 +1,289 @@ +import { createMachine, send, assign } from '@xstate/compiled'; + +export type Attendee = { + id: string; + name: string; + email: string; + timezone: string; + locale: string; +}; + +interface Context { + initialAttendees: Attendee[]; + attendeesToCreate: Attendee[]; + attendeesInList: Attendee[]; + attendeeIdsToDelete: Set; + errorMessage?: string; +} + +type Event = + | { + type: 'EDIT_ATTENDEE'; + attendee: Attendee; + } + | { + type: 'REMOVE_ATTENDEE'; + attendee: Attendee; + } + | { + type: 'EDIT_EMPTY_ATTENDEE'; + attendeeWithoutId: Omit; + } + | { + type: 'GO_BACK'; + } + | { + type: 'SUBMIT'; + } + | { + type: 'REPORT_ERROR'; + } + | { + type: 'done.invoke.createViewing'; + data: string; + }; + +export const addViewingAttendeesMachine = createMachine< + Context, + Event, + 'mattFailTwo' +>( + { + id: 'addViewingAttendees', + initial: 'idle', + entry: [], + states: { + idle: { + on: { + GO_BACK: [ + { + cond: 'inCreateMode', + actions: 'goToPrevPage', + }, + { + cond: 'inEditMode', + actions: 'goBackToEditOverview', + }, + ], + EDIT_ATTENDEE: [ + { + cond: 'isEditingToBeEmpty', + actions: 'removeAttendee', + }, + { + actions: ['editAttendee'], + }, + ], + REMOVE_ATTENDEE: { + actions: 'removeAttendee', + }, + EDIT_EMPTY_ATTENDEE: { + actions: 'addAttendee', + }, + }, + exit: ['clearError'], + initial: 'initial', + states: { + initial: { + on: { + SUBMIT: [ + { + cond: 'hasNotAddedAnyInvitees', + target: 'isWarningThatUserIsNotInvitingAnyone', + }, + { + cond: 'hasInvitedAnInviteeWithoutAName', + actions: 'showNameError', + }, + { + cond: 'hasInvitedAnInviteeWithoutAnEmail', + actions: 'showEmailError', + }, + { + cond: 'currentFormStateIsValidAndInCreateMode', + target: '#creating', + }, + { + cond: 'currentFormStateIsValidAndInUpdateMode', + target: '#updating', + }, + ], + }, + }, + isWarningThatUserIsNotInvitingAnyone: { + on: { + SUBMIT: [ + { + cond: 'currentFormStateIsValidAndInCreateMode', + target: '#creating', + }, + { + cond: 'currentFormStateIsValidAndInUpdateMode', + target: '#updating', + }, + ], + }, + }, + errored: {}, + }, + }, + creating: { + id: 'creating', + invoke: { + src: 'createViewing', + onDone: { + target: 'idle', + actions: 'goToSuccessPage', + }, + onError: { + target: 'idle.errored', + }, + }, + }, + updating: { + id: 'updating', + initial: 'checkingAttendees', + on: { + REPORT_ERROR: { + target: 'idle', + }, + }, + states: { + checkingAttendees: { + always: [ + { + cond: (context) => + Array.from(context.attendeeIdsToDelete).length > 0, + target: 'deletingExcessGuests', + }, + { + cond: (context) => context.attendeesToCreate.length > 0, + target: 'creatingNewAndEditedGuests', + }, + { + target: 'complete', + }, + ], + }, + deletingExcessGuests: { + invoke: { + src: 'deleteExcessGuests', + onDone: [ + { + cond: (context) => context.attendeesToCreate.length > 0, + target: 'creatingNewAndEditedGuests', + }, + { + target: 'complete', + }, + ], + onError: 'errored', + }, + }, + creatingNewAndEditedGuests: { + invoke: { + src: 'createNewGuests', + onDone: [ + { + target: 'complete', + }, + ], + onError: 'errored', + }, + }, + errored: { + entry: [ + send({ + type: 'REPORT_ERROR', + }), + ], + }, + complete: { + type: 'final', + entry: ['goBackToEditOverview', 'showToastWithChangesSaved'], + }, + }, + }, + }, + }, + { + guards: { + isEditingToBeEmpty: (context, event) => { + return ( + event.attendee.email.length === 0 && event.attendee.name.length === 0 + ); + }, + hasInvitedAnInviteeWithoutAName: (context) => { + return context.attendeesInList.some((attendee) => !attendee.name); + }, + hasInvitedAnInviteeWithoutAnEmail: (context) => { + return context.attendeesInList.some((attendee) => !attendee.email); + }, + }, + actions: { + clearError: assign((context, event) => { + return { + errorMessage: '', + }; + }), + showNameError: assign((context, event) => ({ + errorMessage: 'You must provide a name for each guest', + })), + showEmailError: assign((context, event) => ({ + errorMessage: `You must provide an email address for each guest`, + })), + removeAttendee: assign((context, event) => { + let attendeeIdsToDelete = new Set(context.attendeeIdsToDelete); + attendeeIdsToDelete.add(event.attendee.id); + + return { + attendeeIdsToDelete, + attendeesInList: context.attendeesInList.filter( + (attendee) => attendee.id !== event.attendee.id, + ), + attendeesToCreate: context.attendeesToCreate.filter( + (attendee) => attendee.id !== event.attendee.id, + ), + }; + }), + addAttendee: assign((context, event) => { + const newAttendee: Attendee = { + ...event.attendeeWithoutId, + id: '1', + }; + return { + attendeesToCreate: [...context.attendeesToCreate, newAttendee], + attendeesInList: [...context.attendeesInList, newAttendee], + }; + }), + editAttendee: assign((context, event) => { + const attendeeWasOnInitialList = context.initialAttendees.some( + (attendee) => { + return attendee.id === event.attendee.id; + }, + ); + + let attendeeIdsToDelete = new Set(context.attendeeIdsToDelete); + if (attendeeWasOnInitialList) { + attendeeIdsToDelete.add(event.attendee.id); + } + + return { + attendeeIdsToDelete, + attendeesToCreate: [ + ...context.attendeesToCreate.filter( + (attendee) => attendee.id !== event.attendee.id, + ), + event.attendee, + ], + attendeesInList: context.attendeesInList.map((attendee) => { + if (attendee.id === event.attendee.id) { + return event.attendee; + } + return attendee; + }), + }; + }), + }, + }, +); diff --git a/packages/xstate-compiled/examples/matt-fail-3.machine.ts b/packages/xstate-compiled/examples/matt-fail-3.machine.ts new file mode 100644 index 0000000..e175a09 --- /dev/null +++ b/packages/xstate-compiled/examples/matt-fail-3.machine.ts @@ -0,0 +1,26 @@ +import { createMachine } from '@xstate/compiled'; +import { useMachine } from '@xstate/compiled/react'; + +interface Context {} + +type Event = { type: 'CLICK' }; + +const machine = createMachine({ + initial: 'notClicked', + id: 'hasBeenClickedMachine', + states: { + notClicked: { + on: { + CLICK: 'hasBeenClicked', + }, + }, + hasBeenClicked: { + after: { + 5000: 'notClicked', + }, + }, + }, +}); + +export const useHasBeenClicked = () => + useMachine(machine, { devTools: process.env.NODE_ENV === 'development' }); diff --git a/packages/xstate-compiled/examples/nonRequiredOptions.machine.ts b/packages/xstate-compiled/examples/nonRequiredOptions.machine.ts index 3a173eb..b177553 100644 --- a/packages/xstate-compiled/examples/nonRequiredOptions.machine.ts +++ b/packages/xstate-compiled/examples/nonRequiredOptions.machine.ts @@ -1,4 +1,4 @@ -import { Machine, interpret } from '@xstate/compiled'; +import { createMachine, interpret } from '@xstate/compiled'; interface Context {} @@ -8,7 +8,7 @@ type Event = { type: 'MAKE_FETCH' }; * Ensures that optional parameters register as non-required * when passed in as a second param */ -const machine = Machine( +const machine = createMachine( { initial: 'idle', states: { diff --git a/packages/xstate-compiled/examples/options.machine.ts b/packages/xstate-compiled/examples/options.machine.ts index 93d4dda..227bf68 100644 --- a/packages/xstate-compiled/examples/options.machine.ts +++ b/packages/xstate-compiled/examples/options.machine.ts @@ -1,4 +1,4 @@ -import { Machine, interpret } from '@xstate/compiled'; +import { createMachine } from '@xstate/compiled'; import { useMachine } from '@xstate/compiled/react'; interface Context {} @@ -9,7 +9,7 @@ type Event = { type: 'MAKE_FETCH' }; * Ensures that optional parameters register as non-required * when passed in as a second param */ -const machine = Machine( +const machine = createMachine( { initial: 'idle', states: { @@ -35,7 +35,6 @@ const machine = Machine( NON_REQUIRED_DELAY: 'next', REQUIRED_DELAY: { target: 'next', cond: 'delayedCond' }, }, - activities: ['requiredActivity', 'nonRequiredActivity'], }, next: {}, }, @@ -47,9 +46,6 @@ const machine = Machine( services: { nonRequiredService: async () => {}, }, - activities: { - nonRequiredActivity: () => {}, - }, guards: { nonRequiredCond: () => false, }, @@ -67,9 +63,6 @@ const useOptions = () => services: { requiredService: async () => {}, }, - activities: { - requiredActivity: () => {}, - }, guards: { requiredCond: () => true, delayedCond: () => true, diff --git a/packages/xstate-compiled/examples/rootTransitionTargets.machine.ts b/packages/xstate-compiled/examples/rootTransitionTargets.machine.ts index 794de29..fb7fd1a 100644 --- a/packages/xstate-compiled/examples/rootTransitionTargets.machine.ts +++ b/packages/xstate-compiled/examples/rootTransitionTargets.machine.ts @@ -1,6 +1,6 @@ -import { Machine, interpret } from '@xstate/compiled'; +import { createMachine, interpret } from '@xstate/compiled'; -const machine = Machine< +const machine = createMachine< {}, { type: 'EVENT' } | { type: 'EVENT2' }, 'rootTransitionTargets' diff --git a/packages/xstate-compiled/examples/someOtherMachine.machine.ts b/packages/xstate-compiled/examples/someOtherMachine.machine.ts index 89d3836..ddc0f07 100644 --- a/packages/xstate-compiled/examples/someOtherMachine.machine.ts +++ b/packages/xstate-compiled/examples/someOtherMachine.machine.ts @@ -1,4 +1,4 @@ -import { Machine, interpret } from '@xstate/compiled'; +import { createMachine } from '@xstate/compiled'; import { useMachine } from '@xstate/compiled/react'; type FaceEvent = @@ -18,9 +18,8 @@ interface FaceContext { elapsed: number; } -const faceMachine = Machine({ +const faceMachine = createMachine({ type: 'parallel', - initial: undefined, states: { eyes: { initial: 'open', diff --git a/packages/xstate-compiled/examples/trafficLightMachine.machine.ts b/packages/xstate-compiled/examples/trafficLightMachine.machine.ts index d0c9189..e227076 100644 --- a/packages/xstate-compiled/examples/trafficLightMachine.machine.ts +++ b/packages/xstate-compiled/examples/trafficLightMachine.machine.ts @@ -1,4 +1,4 @@ -import { Machine, interpret } from '@xstate/compiled'; +import { createMachine, interpret } from '@xstate/compiled'; import { useMachine } from '@xstate/compiled/react'; type LightEvent = @@ -10,7 +10,7 @@ interface LightContext { elapsed: number; } -const lightMachine = Machine({ +const lightMachine = createMachine({ initial: 'green', context: { elapsed: 0 }, id: 'superMachine', diff --git a/packages/xstate-compiled/examples/withArrayTypeInContext.machine.ts b/packages/xstate-compiled/examples/withArrayTypeInContext.machine.ts new file mode 100644 index 0000000..b5fbf11 --- /dev/null +++ b/packages/xstate-compiled/examples/withArrayTypeInContext.machine.ts @@ -0,0 +1,23 @@ +import { createMachine } from '@xstate/compiled'; + +interface Context { + attendeesToCreate: string[]; +} + +type Event = { type: 'ADD_ATTENDEE'; name: string; email: string }; + +const initialContext: Context = { + attendeesToCreate: [], +}; + +export const addViewingAttendeesMachine = createMachine< + Context, + Event, + 'withArrayTypeInContext' +>({ + context: initialContext, + initial: 'idle', + states: { + idle: {}, + }, +}); diff --git a/packages/xstate-compiled/examples/withConfigMachine.ts b/packages/xstate-compiled/examples/withConfigMachine.ts index af320dd..fe0906f 100644 --- a/packages/xstate-compiled/examples/withConfigMachine.ts +++ b/packages/xstate-compiled/examples/withConfigMachine.ts @@ -1,4 +1,4 @@ -import { Machine, interpret } from '@xstate/compiled'; +import { createMachine } from '@xstate/compiled'; type Data = { yeah: boolean; @@ -13,7 +13,7 @@ type Event = | { type: 'CANCEL' } | { type: 'done.invoke.makeFetch'; data: Data }; -const machine = Machine({ +const machine = createMachine({ initial: 'idle', states: { idle: { diff --git a/packages/xstate-compiled/examples/withConstAssertion.machine.ts b/packages/xstate-compiled/examples/withConstAssertion.machine.ts new file mode 100644 index 0000000..3e09fa3 --- /dev/null +++ b/packages/xstate-compiled/examples/withConstAssertion.machine.ts @@ -0,0 +1,51 @@ +import { createMachine, interpret } from '@xstate/compiled'; + +type Data = { + yeah: boolean; +}; + +interface Context { + data: Data; +} + +type Event = + | { type: 'MAKE_FETCH'; params: { id: string } } + | { type: 'CANCEL' } + | { type: 'done.invoke.makeFetch'; data: Data }; + +let target = ''; + +const machine = createMachine({ + initial: 'idle', + states: { + idle: { + on: { + MAKE_FETCH: 'pending', + }, + }, + pending: { + invoke: { + src: 'makeFetch', + onDone: target as 'success', + }, + }, + success: { + entry: 'celebrate', + }, + }, +}); + +machine.withConfig({ + services: { + makeFetch: () => { + return Promise.resolve({ + yeah: true, + }); + }, + }, + actions: { + celebrate: (context, event) => { + console.log(event.data); + }, + }, +}); diff --git a/packages/xstate-compiled/examples/withIdentifierAsSchema.machine.ts b/packages/xstate-compiled/examples/withIdentifierAsSchema.machine.ts new file mode 100644 index 0000000..eaca7f4 --- /dev/null +++ b/packages/xstate-compiled/examples/withIdentifierAsSchema.machine.ts @@ -0,0 +1,51 @@ +import { createMachine, interpret } from '@xstate/compiled'; + +type Data = { + yeah: boolean; +}; + +interface Context { + data: Data; +} + +type Event = + | { type: 'MAKE_FETCH'; params: { id: string } } + | { type: 'CANCEL' } + | { type: 'done.invoke.makeFetch'; data: Data }; + +const schema = { + initial: 'idle', + states: { + idle: { + on: { + MAKE_FETCH: 'pending', + }, + }, + pending: { + invoke: { + src: 'makeFetch', + onDone: 'success', + }, + }, + success: { + entry: 'celebrate', + }, + }, +} as const; + +const machine = createMachine(schema); + +machine.withConfig({ + services: { + makeFetch: () => { + return Promise.resolve({ + yeah: true, + }); + }, + }, + actions: { + celebrate: (context, event) => { + console.log(event.data); + }, + }, +}); diff --git a/packages/xstate-compiled/examples/withInlineCoreAction.machine.ts b/packages/xstate-compiled/examples/withInlineCoreAction.machine.ts new file mode 100644 index 0000000..d460e63 --- /dev/null +++ b/packages/xstate-compiled/examples/withInlineCoreAction.machine.ts @@ -0,0 +1,48 @@ +import { createMachine, interpret, assign } from '@xstate/compiled'; + +type Data = { + yeah: boolean; +}; + +interface Context { + data: Data; +} + +type Event = + | { type: 'MAKE_FETCH'; params: { id: string } } + | { type: 'CANCEL' } + | { type: 'done.invoke.makeFetch'; data: Data }; + +const machine = createMachine({ + initial: 'idle', + states: { + idle: { + on: { + MAKE_FETCH: 'pending', + }, + }, + pending: { + invoke: [ + { + src: 'makeFetch', + onDone: 'success', + }, + ], + }, + success: { + entry: assign({ + data: (ctx, event) => event.data, + }), + }, + }, +}); + +interpret(machine, { + services: { + makeFetch: () => { + return Promise.resolve({ + yeah: true, + }); + }, + }, +}); diff --git a/packages/xstate-compiled/examples/withInlineFunction.machine.ts b/packages/xstate-compiled/examples/withInlineFunction.machine.ts new file mode 100644 index 0000000..66cff78 --- /dev/null +++ b/packages/xstate-compiled/examples/withInlineFunction.machine.ts @@ -0,0 +1,47 @@ +import { createMachine, interpret } from '@xstate/compiled'; + +type Data = { + yeah: boolean; +}; + +interface Context { + data: Data; +} + +type Event = + | { type: 'MAKE_FETCH'; params: { id: string } } + | { type: 'CANCEL' } + | { type: 'done.invoke.makeFetch'; data: Data }; + +const machine = createMachine({ + initial: 'idle', + states: { + idle: { + on: { + MAKE_FETCH: 'pending', + }, + }, + pending: { + invoke: [ + { + src: 'makeFetch', + onDone: 'success', + }, + ], + entry: (ctx, event) => { + console.log(event.params.id); + }, + }, + success: {}, + }, +}); + +interpret(machine, { + services: { + makeFetch: () => { + return Promise.resolve({ + yeah: true, + }); + }, + }, +}); diff --git a/packages/xstate-compiled/examples/withInlineFunctionOutsideOfMachine.machine.ts b/packages/xstate-compiled/examples/withInlineFunctionOutsideOfMachine.machine.ts new file mode 100644 index 0000000..f6c8140 --- /dev/null +++ b/packages/xstate-compiled/examples/withInlineFunctionOutsideOfMachine.machine.ts @@ -0,0 +1,54 @@ +import { createMachine, interpret } from '@xstate/compiled'; + +type Data = { + yeah: boolean; +}; + +interface Context { + data: Data; +} + +type Event = + | { type: 'MAKE_FETCH'; params: { id: string } } + | { type: 'CANCEL' } + | { type: 'done.invoke.makeFetch'; data: Data }; + +const notify = ( + ctx: Context, + event: { type: 'MAKE_FETCH'; params: { id: string } }, +) => {}; + +const machine = createMachine< + Context, + Event, + 'withInlineFunctionOutsideOfMachine' +>({ + initial: 'idle', + states: { + idle: { + on: { + MAKE_FETCH: 'pending', + }, + }, + pending: { + invoke: [ + { + src: 'makeFetch', + onDone: 'success', + }, + ], + entry: notify, + }, + success: {}, + }, +}); + +interpret(machine, { + services: { + makeFetch: () => { + return Promise.resolve({ + yeah: true, + }); + }, + }, +}); diff --git a/packages/xstate-compiled/examples/withTupleType.machine.ts b/packages/xstate-compiled/examples/withTupleType.machine.ts new file mode 100644 index 0000000..3aeedde --- /dev/null +++ b/packages/xstate-compiled/examples/withTupleType.machine.ts @@ -0,0 +1,51 @@ +import { createMachine, interpret } from '@xstate/compiled'; + +type Data = { + yeah: boolean; +}; + +interface Context { + data: Data; +} + +type Event = + | { type: 'MAKE_FETCH'; params: { id: string } } + | { type: 'CANCEL' } + | { type: 'done.invoke.makeFetch'; data: Data }; + +const schema = { + initial: 'idle' as const, + states: { + idle: { + on: { + MAKE_FETCH: 'pending', + }, + } as const, + pending: { + invoke: { + src: 'makeFetch' as const, + onDone: 'success', + }, + }, + success: { + entry: ['celebrate'] as ['celebrate'], + } as const, + }, +} as const; + +const machine = createMachine(schema); + +machine.withConfig({ + services: { + makeFetch: () => { + return Promise.resolve({ + yeah: true, + }); + }, + }, + actions: { + celebrate: (context, event) => { + console.log(event.data); + }, + }, +}); diff --git a/packages/xstate-compiled/package.json b/packages/xstate-compiled/package.json index 04827c5..e1abf13 100644 --- a/packages/xstate-compiled/package.json +++ b/packages/xstate-compiled/package.json @@ -6,15 +6,6 @@ "license": "MIT", "repository": "https://github.com/mattpocock/xstate-codegen", "dependencies": { - "@babel/core": "^7.10.4", - "@babel/helper-split-export-declaration": "^7.11.0", - "@babel/parser": "^7.10.4", - "@babel/plugin-proposal-nullish-coalescing-operator": "^7.10.4", - "@babel/plugin-proposal-optional-chaining": "^7.10.4", - "@babel/plugin-transform-typescript": "^7.10.4", - "@rollup/plugin-babel": "^5.2.0", - "@rollup/plugin-node-resolve": "^9.0.0", - "babel-plugin-macros": "^2.8.0", "chokidar": "^3.4.3", "colors": "^1.4.0", "glob": "^7.1.6", @@ -22,13 +13,10 @@ "handlebars-helpers": "^0.10.0", "pkg-up": "^3.1.0", "rimraf": "^3.0.2", - "rollup": "^2.26.3", + "ts-morph": "^10.0.1", "xstate": "^4.12.0" }, "devDependencies": { - "@changesets/cli": "^2.9.2", - "@types/babel-plugin-macros": "^2.8.2", - "@types/babel__core": "^7.1.9", "@types/gaze": "^1.1.0", "@types/glob": "^7.1.3", "@types/handlebars-helpers": "^0.5.2", @@ -37,16 +25,13 @@ "@types/rimraf": "^3.0.0", "@xstate/react": "^0.8.1", "nodemon": "2.0.4", + "ts-node": "^9.0.0", "typescript": "^3.9.7" }, "scripts": { - "local-link": "yarn unlink && npm run build && npm run chmod:index && yarn link", "build": "rm -rf bin && tsc && cp -r src/templates bin/templates", - "prepare": "npm run build", - "prepublishOnly": "npm run test && npm run build", "test": "node test.js", - "test:watch": "nodemon test.js", - "chmod:index": "chmod +x bin/index.js" + "test:watch": "nodemon test.js" }, "nodemonConfig": { "watch": [ diff --git a/packages/xstate-compiled/src/extractMachines.ts b/packages/xstate-compiled/src/extractMachines.ts index 44f618c..2f95e1c 100644 --- a/packages/xstate-compiled/src/extractMachines.ts +++ b/packages/xstate-compiled/src/extractMachines.ts @@ -1,346 +1,175 @@ -import * as babelCore from '@babel/core'; -import { Scope } from '@babel/traverse'; -// @ts-ignore -import splitExportDeclaration from '@babel/helper-split-export-declaration'; import path from 'path'; -import babelPluginMacros, { createMacro } from 'babel-plugin-macros'; -import { StateMachine } from 'xstate'; -import { rollup } from 'rollup'; -import babelPlugin from '@rollup/plugin-babel'; -import nodeResolvePlugin from '@rollup/plugin-node-resolve'; -import Module from 'module'; +import { StateMachine, createMachine } from 'xstate'; +import { Project, ts, Node } from 'ts-morph'; +import { extractSchema, extractOptions } from './extractor'; -const generateRandomId = (): string => - Math.random() - .toString(36) - .substring(2); - -const generateUniqueId = (map: Record): string => { - const id = generateRandomId(); - return Object.prototype.hasOwnProperty.call(map, id) - ? generateUniqueId(map) - : id; +type ExtractedMachine = { + id: string; + machine: StateMachine; }; -const compiledOutputs: Record = Object.create(null); -(Module as any)._extensions['.xstate.js'] = (module: any, filename: string) => { - const [_match, id] = filename.match(/-(\w+)\.xstate\.js$/)!; - module._compile(compiledOutputs[id], filename); -}; +let projectCache = new Map(); -type UsedImport = { - localName: string; - importedName: string; +Array.prototype.flatMap = function(iteratee) { + return [].concat(...(this.map(iteratee) as any)); }; -type ReferencePathsByImportName = Record< - string, - Array> ->; - -const cwd = process.cwd(); -const extensions = ['.tsx', '.ts', '.jsx', '.js']; - -const getImports = ( - { types: t }: typeof babelCore, - path: babelCore.NodePath, -): UsedImport[] => { - return path.node.specifiers.map((specifier) => { - if (t.isImportNamespaceSpecifier(specifier)) { - throw new Error( - 'Using a namespace import for `@xstate/import` is not supported.', - ); - } - return { - localName: specifier.local.name, - importedName: - specifier.type === 'ImportDefaultSpecifier' - ? 'default' - : specifier.local.name, - }; - }); -}; +const getTsPropertyNameText = (propertyName: ts.PropertyName): string => { + if ( + ts.isIdentifier(propertyName) || + ts.isStringLiteral(propertyName) || + ts.isNumericLiteral(propertyName) + ) { + return propertyName.text; + } -const getReferencePathsByImportName = ( - scope: Scope, - imports: UsedImport[], -): ReferencePathsByImportName | undefined => { - let shouldExit = false; - let hasReferences = false; - const referencePathsByImportName = imports.reduce( - (byName, { importedName, localName }) => { - let binding = scope.getBinding(localName); - if (!binding) { - shouldExit = true; - return byName; - } - byName[importedName] = binding.referencePaths; - hasReferences = hasReferences || Boolean(byName[importedName].length); - return byName; - }, - {} as ReferencePathsByImportName, - ); + if (ts.isComputedPropertyName(propertyName)) { + throw new Error( + "Private identifiers can't be used as property names within config object.", + ); + } - if (!hasReferences || shouldExit) { - return; + if (ts.isPrivateIdentifier(propertyName)) { + throw new Error( + "Private identifiers can't be used as property names within config object.", + ); } - return referencePathsByImportName; + // propertyName is already never here, but TS doesn't recognize that this explores all possibilities here + // we have to throw so it doesn't complain about the string return type + throw new Error('This should be unreachable.'); }; -const getMachineId = ( - importName: string, - { types: t }: typeof babelCore, - callExpression: babelCore.types.CallExpression, -) => { - const { typeParameters } = callExpression; +export const extractMachines = async ( + filePath: string, +): Promise => { + const resolvedFilePath = path.resolve(process.cwd(), filePath); - if ( - !typeParameters || - !typeParameters.params[2] || - !t.isTSLiteralType(typeParameters.params[2]) || - !t.isStringLiteral(typeParameters.params[2].literal) - ) { - console.log('You must pass three type arguments to your machine.'); - console.log(); - console.log('For instance:'); - console.log( - `const machine = ${importName}({})`, - ); - console.log(); - throw new Error('You must pass three type arguments to your machine.'); + let configFileName = ts.findConfigFile(resolvedFilePath, ts.sys.fileExists); + if (!configFileName) { + throw new Error('No tsconfig.json file could be found'); } - return typeParameters.params[2].literal.value; -}; -const insertExtractingExport = ( - { types: t }: typeof babelCore, - statementPath: babelCore.NodePath, - { - importName, - index, - machineId, - machineIdentifier, - }: { - importName: string; - index: number; - machineId: string; - machineIdentifier: string; - }, -) => { - statementPath.insertAfter( - t.exportNamedDeclaration( - t.variableDeclaration('var', [ - t.variableDeclarator( - t.identifier(`__xstate_${importName}_${index}`), - t.objectExpression([ - t.objectProperty(t.identifier('id'), t.stringLiteral(machineId)), - t.objectProperty( - t.identifier('machine'), - t.identifier(machineIdentifier), - ), - ]), - ), - ]), - ), - ); -}; - -const handleMachineFactoryCalls = ( - importName: string, - { references, babel }: babelPluginMacros.MacroParams, -) => { - if (!references[importName]) { - return; + let isFreshProject = false; + if (!projectCache.has(configFileName)) { + isFreshProject = true; + const cachedProject = new Project({ + tsConfigFilePath: configFileName, + // addFilesFromTsConfig: false, + }); + projectCache.set(configFileName, cachedProject); + } + let project = projectCache.get(configFileName)!; + project.addSourceFileAtPath(resolvedFilePath); + project.resolveSourceFileDependencies(); + + if (!isFreshProject) { + let sourceFiles = project.getSourceFiles(); + for (let sourceFile of sourceFiles) { + sourceFile.refreshFromFileSystemSync(); + } } - const { types: t } = babel; + let sourceFile = project.getSourceFileOrThrow(resolvedFilePath); + + const machineReferences = sourceFile + .getImportDeclarations() + .filter( + (importDeclar) => + importDeclar.getModuleSpecifierValue() === '@xstate/compiled', + ) + .flatMap((importDeclar) => { + if (importDeclar.getNamespaceImport()) { + throw new Error('Namespace imports are not supported yet.'); + } - references[importName].forEach((referencePath, index) => { - const callExpressionPath = referencePath.parentPath; + return importDeclar.getNamedImports(); + }) + .filter( + (namedImport) => + namedImport.getNameNode().compilerNode.text === 'createMachine', + ) + .flatMap((namedImport) => + ( + namedImport.getAliasNode() || namedImport.getNameNode() + ).findReferences(), + ) + .flatMap((references) => references.getReferences()) + .map((reference) => reference.getNode()) + .filter((referenceNode) => { + if (referenceNode.getSourceFile() !== sourceFile) { + return false; + } + const statement = referenceNode.getFirstAncestor(Node.isStatement); + return !statement || !Node.isImportDeclaration(statement); + }); - if (!t.isCallExpression(callExpressionPath.node)) { - throw new Error(`\`${importName}\` can only be called.`); - } - const machineId = getMachineId(importName, babel, callExpressionPath.node); + return machineReferences.map((machineReference) => { + const machineCall = machineReference.getParent()!; - const callExpressionParentPath = callExpressionPath.parentPath; - const callExpressionParentNode = callExpressionParentPath.node; + if ( + !Node.isCallExpression(machineCall) || + machineCall.getExpression() !== machineReference + ) { + throw new Error( + "`Machine` can only be called - you can't pass it around or do anything else with it.", + ); + } - switch (callExpressionParentNode.type) { - case 'VariableDeclarator': { - if (!t.isIdentifier(callExpressionParentNode.id)) { - throw new Error( - `Result of the \`${importName}\` call can only appear in the variable declaration.`, - ); + const configNode = machineCall.getArguments()[0]; + if (Node.isObjectLiteralExpression(configNode)) { + configNode.transform((traversal) => { + if (traversal.currentNode === configNode.compilerNode) { + return traversal.visitChildren(); } - const statementPath = callExpressionParentPath.getStatementParent(); - if (!statementPath.parentPath.isProgram()) { - throw new Error( - `\`${importName}\` calls can only appear in top-level statements.`, + + if ( + ts.isPropertyAssignment(traversal.currentNode) && + getTsPropertyNameText(traversal.currentNode.name) !== 'context' && + (ts.isObjectLiteralExpression(traversal.currentNode.initializer) || + ts.isArrayLiteralExpression(traversal.currentNode.initializer) || + ts.isStringLiteral(traversal.currentNode.initializer)) + ) { + return ts.updatePropertyAssignment( + traversal.currentNode, + traversal.currentNode.name, + ts.factory.createAsExpression( + traversal.currentNode.initializer, + ts.factory.createTypeReferenceNode( + ts.factory.createIdentifier('const'), + undefined, + ), + ), ); } - insertExtractingExport(babel, statementPath, { - importName, - index, - machineId, - machineIdentifier: callExpressionParentNode.id.name, - }); - - break; - } - case 'ExportDefaultDeclaration': { - splitExportDeclaration(callExpressionParentPath); - - insertExtractingExport( - babel, - callExpressionParentPath.getStatementParent(), - { - importName, - index, - machineId, - machineIdentifier: ((callExpressionParentPath as babelCore.NodePath< - babelCore.types.VariableDeclaration - >).node.declarations[0].id as babelCore.types.Identifier).name, - }, - ); - break; - } - default: { - throw new Error( - `\`${importName}\` calls can only appear in the variable declaration or as a default export.`, - ); - } + return traversal.currentNode; + }); } - }); -}; -const macro = createMacro((params) => { - handleMachineFactoryCalls('createMachine', params); - handleMachineFactoryCalls('Machine', params); -}); + const stateSchema = extractSchema(configNode.getType()); + const optionsNode = machineCall.getArguments()[1]; + const options = optionsNode && extractOptions(optionsNode.getType()); -type ExtractedMachine = { - id: string; - machine: StateMachine; -}; + const secondTypeArg = machineCall.getTypeArguments()[2]; -const getCreatedExports = ( - importName: string, - exportsObj: Record, -): ExtractedMachine[] => { - const extracted: ExtractedMachine[] = []; - let counter = 0; - while (true) { - const currentCandidate = exportsObj[`__xstate_${importName}_${counter++}`]; - if (!currentCandidate) { - return extracted; + if (!Node.isLiteralTypeNode(secondTypeArg)) { + throw new Error( + 'Second type argument passed to `Machine` has to be a string literal.', + ); } - extracted.push(currentCandidate); - } -}; - -export const extractMachines = async ( - filePath: string, -): Promise => { - const resolvedFilePath = path.resolve(cwd, filePath); - const build = await rollup({ - input: resolvedFilePath, - external: (id) => !/^(\.|\/|\w:)/.test(id), - plugins: [ - nodeResolvePlugin({ - extensions, - }), - babelPlugin({ - babelHelpers: 'bundled', - extensions, - plugins: [ - '@babel/plugin-transform-typescript', - '@babel/plugin-proposal-optional-chaining', - '@babel/plugin-proposal-nullish-coalescing-operator', - (babel: typeof babelCore) => { - return { - name: 'xstate-codegen-machines-extractor', - visitor: { - ImportDeclaration( - path: babelCore.NodePath, - state: babelCore.PluginPass, - ) { - if ( - state.filename !== resolvedFilePath || - path.node.source.value !== '@xstate/compiled' - ) { - return; - } + const literal = secondTypeArg.getLiteral(); - const imports = getImports(babel, path); - const referencePathsByImportName = getReferencePathsByImportName( - path.scope, - imports, - ); - - if (!referencePathsByImportName) { - return; - } - - /** - * Other plugins that run before babel-plugin-macros might use path.replace, where a path is - * put into its own replacement. Apparently babel does not update the scope after such - * an operation. As a remedy, the whole scope is traversed again with an empty "Identifier" - * visitor - this makes the problem go away. - * - * See: https://github.com/kentcdodds/import-all.macro/issues/7 - */ - state.file.scope.path.traverse({ - Identifier() {}, - }); + if (!Node.isStringLiteral(literal)) { + throw new Error( + 'Second type argument passed to `Machine` has to be a string literal.', + ); + } - macro({ - path, - references: referencePathsByImportName, - state, - babel, - // hack to make this call accepted by babel-plugin-macros - isBabelMacrosCall: true, - }); - }, - }, - }; - }, - ], - }), - ], - }); - const output = await build.generate({ - format: 'cjs', - exports: 'named', + return { + id: literal.getLiteralValue(), + machine: createMachine(stateSchema as any, options as any), + }; }); - const chunk = output.output[0]; - const { code } = chunk; - - // dance with those unique ids is not really needed, at least right now - // loading CJS modules is synchronous - // once we start to support loading ESM this won't hold true anymore - let uniqueId = generateUniqueId(compiledOutputs); - - try { - compiledOutputs[uniqueId] = code; - const fakeFileName = path.join( - path.dirname(resolvedFilePath), - `${path - .basename(resolvedFilePath) - .replace(/\./g, '-')}-${uniqueId}.xstate.js`, - ); - const module = new Module(fakeFileName); - (module as any).load(fakeFileName); - - return [ - ...getCreatedExports('createMachine', module.exports), - ...getCreatedExports('Machine', module.exports), - ]; - } finally { - delete compiledOutputs[uniqueId]; - } }; diff --git a/packages/xstate-compiled/src/extractor.ts b/packages/xstate-compiled/src/extractor.ts new file mode 100644 index 0000000..0ed854e --- /dev/null +++ b/packages/xstate-compiled/src/extractor.ts @@ -0,0 +1,332 @@ +import path from 'path'; +import { Type } from 'ts-morph'; + +const knownActions = new Set([ + 'AssignAction', + 'ChooseAction', + 'LogAction', + 'PureAction', + 'RaiseAction', + 'SendAction', +]); + +const dummyNamedFunction = () => {}; + +const findLastIndex = (arr: T[], predicate: (el: T) => boolean): number => { + for (let index = arr.length - 1; index >= 0; index--) { + if (predicate(arr[index])) { + return index; + } + } + return -1; +}; + +const explodeAbsolutePath = (filePath: string): string[] => { + if (!path.isAbsolute(filePath)) { + throw new Error(`Received file path is not an absolute one: ${filePath}`); + } + const parsed = path.parse(filePath); + return [...parsed.dir.slice(parsed.root.length).split(path.sep), parsed.base]; +}; + +const isNodeModulePath = ( + moduleName: string, + absoluteFilePath: string, +): boolean => { + if (!moduleName.length) { + throw new Error('Received `moduleName` has to be non-empty.'); + } + + const explodedPath = explodeAbsolutePath(absoluteFilePath); + const nodeModulesIndex = findLastIndex( + explodedPath, + (segment) => segment === 'node_modules', + ); + + if (nodeModulesIndex === -1) { + return false; + } + + if (moduleName[0] === '@') { + return ( + `${explodedPath[nodeModulesIndex + 1]}/${ + explodedPath[nodeModulesIndex + 2] + }` === moduleName + ); + } + + return explodedPath[nodeModulesIndex + 1] === moduleName; +}; + +const indexer = Symbol('schema.extractor.indexer'); + +type TypeExtractor = { + extract: ( + type: Type | undefined, + ) => [true, undefined] | [false, any, boolean?]; +}; + +const lazy = (getter: () => TypeExtractor): TypeExtractor => ({ + extract: (type: Type | undefined) => getter().extract(type), +}); + +const object = ( + shape: Record, +): TypeExtractor => ({ + extract(type: Type | undefined) { + if (!type?.isObject()) { + return [true, undefined]; + } + + if (type.getStringIndexType() || type.getNumberIndexType()) { + return [true, undefined]; + } + + const extracted: Record = {}; + for (const propertySymbol of type.getProperties()) { + const propName = propertySymbol.getName(); + const propExtractor = shape[propName] || shape[indexer as any]; + + if (!propExtractor) { + // for now ignore properties not known to the shape + // TODO: rethink if that's the best solution + // list pros and cons of the extractor being strict versus it only handling what it knows + continue; + } + + const [err, value, hasValue] = propExtractor.extract( + propertySymbol.getValueDeclarationOrThrow().getType(), + ); + if (err) { + return [err, undefined]; + } + if (hasValue) { + extracted[propName] = value; + } + } + + return [false, extracted, true]; + }, +}); + +const optional = (t: TypeExtractor): TypeExtractor => ({ + extract(type: Type | undefined) { + // TODO: should this accept explicit undefined as well? + if (!type) { + return [false, undefined, false]; + } + return t.extract(type); + }, +}); + +const array = (typeExtractor: TypeExtractor): TypeExtractor => ({ + extract(type: Type | undefined) { + if (!type?.isTuple()) { + return [true, undefined]; + } + + const result = []; + + for (const element of type.getTupleElements()) { + const [err, value, hasValue] = typeExtractor.extract(element); + if (err) { + return [err, undefined]; + } + if (hasValue) { + result.push(value); + } + } + return [false, result, true]; + }, +}); +const match = (candidates: TypeExtractor[]): TypeExtractor => ({ + extract(type: Type | undefined) { + for (const candidate of candidates) { + const [, value, hasValue] = candidate.extract(type); + if (hasValue) { + return [false, value, true]; + } + } + + return [true, undefined]; + }, +}); +const undef = (): TypeExtractor => ({ + extract(type: Type | undefined) { + if (!type?.isUndefined()) { + return [true, undefined]; + } + return [false, undefined, true]; + }, +}); +const bool = (literal?: boolean): TypeExtractor => ({ + extract(type: Type | undefined) { + if (!type?.isBooleanLiteral()) { + return [true, undefined]; + } + const actual = (type.compilerType as any).intrinsicName === 'true'; + if (literal !== undefined && literal !== actual) { + return [true, undefined]; + } + return [false, actual, true]; + }, +}); +const string = (literals?: string[]): TypeExtractor => ({ + extract(type: Type | undefined) { + if (!type?.isStringLiteral()) { + return [true, undefined]; + } + + const literal = (type.compilerType as any).value; + if (!literals || literals.includes(literal)) { + return [false, literal, true]; + } + return [true, undefined]; + }, +}); +const number = (): TypeExtractor => ({ + extract(type: Type | undefined) { + if (!type?.isNumber()) { + return [true, undefined]; + } + // provide a dummy value since for numbers we don't need to extract literals right now + return [false, 10, true]; + }, +}); + +const func = (): TypeExtractor => ({ + extract(type: Type | undefined) { + if (!type?.getCallSignatures().length) { + return [true, undefined]; + } + return [false, dummyNamedFunction, true]; + }, +}); + +const SingleOrArray = (typeExtractor: TypeExtractor): TypeExtractor => + match([typeExtractor, array(typeExtractor)]); + +const Action = (): TypeExtractor => ({ + extract(type: Type | undefined) { + if (!type?.isObject()) { + return [true, undefined]; + } + + const symbol = type.getSymbol(); + + if (!symbol) { + return [true, undefined]; + } + + if ( + !knownActions.has(symbol.getName()) || + !symbol + .getDeclarations() + .some((declaration) => + isNodeModulePath('xstate', declaration.getSourceFile().getFilePath()), + ) + ) { + return [true, undefined]; + } + + return [false, dummyNamedFunction, true]; + }, +}); +const Actions = SingleOrArray(match([string(), func(), Action()])); + +const Target = match([undef(), SingleOrArray(string())]); + +const Transition = match([ + Target, + object({ + target: optional(Target), + cond: optional(match([string(), func()])), + actions: optional(Actions), + internal: optional(bool()), + }), +]); + +const TransitionsMap = object({ + [indexer]: SingleOrArray(Transition), +}); + +const Invoke = SingleOrArray( + object({ + // TODO: this can be an object with .type + src: string(), + id: optional(string()), + onDone: optional(SingleOrArray(Transition)), + onError: optional(SingleOrArray(Transition)), + autoForward: optional(bool()), + // TODO: + // data: + }), +); + +const State = object({ + type: optional( + string(['atomic', 'compound', 'parallel', 'final', 'history']), + ), + id: optional(string()), + initial: optional(string()), + entry: optional(Actions), + exit: optional(Actions), + invoke: optional(Invoke), + on: optional(TransitionsMap), + after: optional(TransitionsMap), + always: optional(SingleOrArray(Transition)), + states: optional(lazy(() => States)), + onDone: optional(SingleOrArray(Transition)), + // TODO: supported on final states, implement it + // data: ? + history: optional(match([string(['shallow', 'deep']), bool(true)])), + // XState seems to allow undefined here, that's weird? what would it mean? + // it also only allows StateValue, need to recheck how the whole thing behaves + // let's keep this defined as a simple string for now + target: optional(string()), +}); + +const States = object({ + [indexer]: State, +}); + +const Options = optional( + object({ + actions: optional( + object({ + [indexer]: match([func(), Action()]), + }), + ), + delays: optional( + object({ + [indexer]: match([func(), number()]), + }), + ), + guards: optional( + object({ + [indexer]: func(), + }), + ), + services: optional( + object({ + [indexer]: func(), + }), + ), + }), +); + +export const extractSchema = (type: Type) => { + const [error, schema] = State.extract(type); + if (error) { + throw new Error('Could not extract state schema'); + } + return schema; +}; + +export const extractOptions = (type: Type) => { + const [error, options] = Options.extract(type); + if (error) { + throw new Error('Could not extract options'); + } + return options; +}; diff --git a/packages/xstate-compiled/src/fake_node_modules/@xstate/compiled/index.js b/packages/xstate-compiled/src/fake_node_modules/@xstate/compiled/index.js deleted file mode 100644 index 213502c..0000000 --- a/packages/xstate-compiled/src/fake_node_modules/@xstate/compiled/index.js +++ /dev/null @@ -1 +0,0 @@ -module.exports = require('xstate'); diff --git a/packages/xstate-compiled/src/index.ts b/packages/xstate-compiled/src/index.ts index 55ff976..75c1a49 100755 --- a/packages/xstate-compiled/src/index.ts +++ b/packages/xstate-compiled/src/index.ts @@ -30,6 +30,7 @@ const fileCache: Record< > = {}; printJsFiles(); +printToFile(fileCache, objectArgs.outDir); if (!onlyOnce) { console.clear(); } @@ -49,22 +50,33 @@ watcher.on('all', async (eventName, filePath) => { if (!isValidFile(filePath)) { return; } - let message = ''; + const relativePath = toRelative(filePath).gray; if (eventName === 'add') { - message += `Scanning File: `.cyan.bold; - await addToCache(filePath); + console.log(`Scanning File: `.cyan.bold + ` ${relativePath}`); + try { + await addToCache(filePath); + } catch (err) { + console.log( + `Could not complete due to errors in ${relativePath}`.red.bold, + ); + console.log(err); + } } if (eventName === 'change') { - message += `File Changed: `.yellow.bold; - await addToCache(filePath); + console.log(`File Changed: `.yellow.bold + ` ${relativePath}`); + try { + await addToCache(filePath); + } catch (err) { + console.log( + `Could not complete due to errors in ${relativePath}`.red.bold, + ); + console.log(err); + } } if (eventName === 'unlink') { - message += `File Deleted: `.red.bold; + console.log(`File Deleted: `.red.bold + ` ${relativePath}`); removeFromCache(filePath); } - if (message) { - console.log(`${message} ${toRelative(filePath).gray}`); - } printToFile(fileCache, objectArgs.outDir); }); diff --git a/packages/xstate-compiled/src/introspectMachine.ts b/packages/xstate-compiled/src/introspectMachine.ts index 1ae029a..bce7980 100644 --- a/packages/xstate-compiled/src/introspectMachine.ts +++ b/packages/xstate-compiled/src/introspectMachine.ts @@ -1,6 +1,6 @@ import 'colors'; import * as XState from 'xstate'; -import { toStateValue, toStatePaths, pathToStateValue } from 'xstate/lib/utils'; +import { toStatePaths, pathToStateValue } from 'xstate/lib/utils'; import { getTransitionsFromNode } from './traversalUtils'; export interface SubState { @@ -26,6 +26,19 @@ export const getMatchesStates = (machine: XState.StateNode) => { return states; }; +const toCompactArray = (maybeArray: T | T[] | undefined): T[] => { + if (!maybeArray) { + return []; + } + if (Array.isArray(maybeArray)) { + return maybeArray; + } + return [maybeArray]; +}; + +const getStringActions = (_actions: any): string[] => + toCompactArray(_actions).filter((action) => typeof action === 'string'); + const makeSubStateFromNode = ( node: XState.StateNode, rootNode: XState.StateNode, @@ -134,8 +147,6 @@ class ItemMap { } } -const xstateRegex = /^xstate\./; - export const introspectMachine = (machine: XState.StateNode) => { const guards = new ItemMap({ checkIfOptional: (name) => Boolean(machine.options.guards[name]), @@ -164,14 +175,14 @@ export const introspectMachine = (machine: XState.StateNode) => { machine.getStateNodeById(id), ); - allStateNodes?.forEach((node) => { + allStateNodes.forEach((node) => { nodeMaps[node.id] = { sources: new Set(), children: new Set(), }; }); - allStateNodes?.forEach((node) => { + allStateNodes.forEach((node) => { Object.values(node.states)?.forEach((childNode) => { nodeMaps[node.id].children.add(childNode.id); }); @@ -227,62 +238,31 @@ export const introspectMachine = (machine: XState.StateNode) => { }, ); - if (transition.actions) { - transition.actions?.forEach((action) => { - if (!xstateRegex.test(action.type)) { - actions.addEventToItem( - action.type, - transition.eventType, - node.path, - ); - } - if (action.type === 'xstate.choose' && Array.isArray(action.conds)) { - action.conds.forEach(({ cond, actions: condActions }) => { - if (typeof cond === 'string') { - guards.addEventToItem(cond, transition.eventType, node.path); - } - if (Array.isArray(condActions)) { - condActions.forEach((condAction) => { - if (typeof condAction === 'string') { - actions.addEventToItem( - condAction, - transition.eventType, - node.path, - ); - } - }); - } else if (typeof condActions === 'string') { - actions.addEventToItem( - condActions, - transition.eventType, - node.path, - ); - } - }); - } - return { - name: action.type, - event: transition.eventType, - }; + transition.actions + .filter((action) => !/^xstate\./.test(action.type)) + .forEach((action) => { + actions.addEventToItem(action.type, transition.eventType, node.path); }); - } }); }); - allStateNodes?.forEach((node) => { - const allActions: XState.ActionObject[] = []; - allActions.push(...node.onExit); - allActions.push(...node.onEntry); + allStateNodes.forEach((node) => { + const allActions: string[] = []; + + const stringEntryActions = getStringActions(node.config.entry); + const stringExitActions = getStringActions(node.config.exit); + + allActions.push(...stringEntryActions); + allActions.push(...stringExitActions); - allActions?.forEach((action) => { - if (xstateRegex.test(action.type) || action.exec) return; - actions.addItem(action.type, node.path); + allActions.forEach((action) => { + actions.addItem(action, node.path); }); - node.onEntry?.forEach((action) => { + stringEntryActions.forEach((action) => { const sources = nodeMaps[node.id].sources; sources?.forEach((source) => { - actions.addEventToItem(action.type, source, node.path); + actions.addEventToItem(action, source, node.path); }); }); }); diff --git a/packages/xstate-compiled/src/utils.ts b/packages/xstate-compiled/src/utils.ts new file mode 100644 index 0000000..fa61f6d --- /dev/null +++ b/packages/xstate-compiled/src/utils.ts @@ -0,0 +1,50 @@ +import path from 'path'; + +export const findLastIndex = ( + arr: T[], + predicate: (el: T) => boolean, +): number => { + for (let index = arr.length - 1; index >= 0; index--) { + if (predicate(arr[index])) { + return index; + } + } + return -1; +}; + +export const explodeAbsolutePath = (filePath: string): string[] => { + if (!path.isAbsolute(filePath)) { + throw new Error(`Received file path is not an absolute one: ${filePath}`); + } + const parsed = path.parse(filePath); + return [...parsed.dir.slice(parsed.root.length).split(path.sep), parsed.base]; +}; + +export const isNodeModulePath = ( + moduleName: string, + absoluteFilePath: string, +) => { + if (!moduleName.length) { + throw new Error('Received `moduleName` has to be non-empty.'); + } + + const explodedPath = explodeAbsolutePath(absoluteFilePath); + const nodeModulesIndex = findLastIndex( + explodedPath, + (segment) => segment === 'node_modules', + ); + + if (nodeModulesIndex === -1) { + return false; + } + + if (moduleName[0] === '@') { + return ( + `${explodedPath[nodeModulesIndex + 1]}/${ + explodedPath[nodeModulesIndex + 2] + }` === moduleName + ); + } + + return explodedPath[nodeModulesIndex + 1] === moduleName; +}; diff --git a/packages/xstate-compiled/tsconfig.json b/packages/xstate-compiled/tsconfig.json index 3835929..d332ef3 100644 --- a/packages/xstate-compiled/tsconfig.json +++ b/packages/xstate-compiled/tsconfig.json @@ -1,7 +1,7 @@ { "compilerOptions": { "types": [ - "node", + "node" ], "allowJs": true, "esModuleInterop": true, @@ -11,9 +11,12 @@ "moduleResolution": "node", "resolveJsonModule": true, "strictNullChecks": true, - "outDir": "bin" + "outDir": "bin", + "baseUrl": "src", + "noEmitOnError": false, + "target": "ES2017", + "module": "CommonJS", + "lib": ["ES2020"] }, - "include": [ - "src", - ] -} \ No newline at end of file + "include": ["src"] +} diff --git a/yarn.lock b/yarn.lock index 1be2be8..b148f9a 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2,350 +2,120 @@ # yarn lockfile v1 -"@babel/code-frame@^7.0.0", "@babel/code-frame@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.10.4.tgz#168da1a36e90da68ae8d49c0f1b48c7c6249213a" - integrity sha512-vG6SvB6oYEhvgisZNFRmRCUkLz11c7rp+tbNTynGqc6mS1d5ATd/sGyV6W0KZZnXRKMTzZDRgQT3Ou9jhpAfUg== - dependencies: - "@babel/highlight" "^7.10.4" - -"@babel/core@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.10.4.tgz#780e8b83e496152f8dd7df63892b2e052bf1d51d" - integrity sha512-3A0tS0HWpy4XujGc7QtOIHTeNwUgWaZc/WuS5YQrfhU67jnVmsD6OGPc1AKHH0LJHQICGncy3+YUjIhVlfDdcA== - dependencies: - "@babel/code-frame" "^7.10.4" - "@babel/generator" "^7.10.4" - "@babel/helper-module-transforms" "^7.10.4" - "@babel/helpers" "^7.10.4" - "@babel/parser" "^7.10.4" - "@babel/template" "^7.10.4" - "@babel/traverse" "^7.10.4" - "@babel/types" "^7.10.4" - convert-source-map "^1.7.0" - debug "^4.1.0" - gensync "^1.0.0-beta.1" - json5 "^2.1.2" - lodash "^4.17.13" - resolve "^1.3.2" - semver "^5.4.1" - source-map "^0.5.0" - -"@babel/generator@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.10.4.tgz#e49eeed9fe114b62fa5b181856a43a5e32f5f243" - integrity sha512-toLIHUIAgcQygFZRAQcsLQV3CBuX6yOIru1kJk/qqqvcRmZrYe6WavZTSG+bB8MxhnL9YPf+pKQfuiP161q7ng== - dependencies: - "@babel/types" "^7.10.4" - jsesc "^2.5.1" - lodash "^4.17.13" - source-map "^0.5.0" - -"@babel/helper-create-class-features-plugin@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.10.4.tgz#2d4015d0136bd314103a70d84a7183e4b344a355" - integrity sha512-9raUiOsXPxzzLjCXeosApJItoMnX3uyT4QdM2UldffuGApNrF8e938MwNpDCK9CPoyxrEoCgT+hObJc3mZa6lQ== - dependencies: - "@babel/helper-function-name" "^7.10.4" - "@babel/helper-member-expression-to-functions" "^7.10.4" - "@babel/helper-optimise-call-expression" "^7.10.4" - "@babel/helper-plugin-utils" "^7.10.4" - "@babel/helper-replace-supers" "^7.10.4" - "@babel/helper-split-export-declaration" "^7.10.4" - -"@babel/helper-function-name@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.10.4.tgz#d2d3b20c59ad8c47112fa7d2a94bc09d5ef82f1a" - integrity sha512-YdaSyz1n8gY44EmN7x44zBn9zQ1Ry2Y+3GTA+3vH6Mizke1Vw0aWDM66FOYEPw8//qKkmqOckrGgTYa+6sceqQ== - dependencies: - "@babel/helper-get-function-arity" "^7.10.4" - "@babel/template" "^7.10.4" - "@babel/types" "^7.10.4" - -"@babel/helper-get-function-arity@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/helper-get-function-arity/-/helper-get-function-arity-7.10.4.tgz#98c1cbea0e2332f33f9a4661b8ce1505b2c19ba2" - integrity sha512-EkN3YDB+SRDgiIUnNgcmiD361ti+AVbL3f3Henf6dqqUyr5dMsorno0lJWJuLhDhkI5sYEpgj6y9kB8AOU1I2A== - dependencies: - "@babel/types" "^7.10.4" - -"@babel/helper-member-expression-to-functions@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.10.4.tgz#7cd04b57dfcf82fce9aeae7d4e4452fa31b8c7c4" - integrity sha512-m5j85pK/KZhuSdM/8cHUABQTAslV47OjfIB9Cc7P+PvlAoBzdb79BGNfw8RhT5Mq3p+xGd0ZfAKixbrUZx0C7A== - dependencies: - "@babel/types" "^7.10.4" - -"@babel/helper-module-imports@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.10.4.tgz#4c5c54be04bd31670a7382797d75b9fa2e5b5620" - integrity sha512-nEQJHqYavI217oD9+s5MUBzk6x1IlvoS9WTPfgG43CbMEeStE0v+r+TucWdx8KFGowPGvyOkDT9+7DHedIDnVw== - dependencies: - "@babel/types" "^7.10.4" - -"@babel/helper-module-transforms@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.10.4.tgz#ca1f01fdb84e48c24d7506bb818c961f1da8805d" - integrity sha512-Er2FQX0oa3nV7eM1o0tNCTx7izmQtwAQsIiaLRWtavAAEcskb0XJ5OjJbVrYXWOTr8om921Scabn4/tzlx7j1Q== - dependencies: - "@babel/helper-module-imports" "^7.10.4" - "@babel/helper-replace-supers" "^7.10.4" - "@babel/helper-simple-access" "^7.10.4" - "@babel/helper-split-export-declaration" "^7.10.4" - "@babel/template" "^7.10.4" - "@babel/types" "^7.10.4" - lodash "^4.17.13" - -"@babel/helper-optimise-call-expression@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.10.4.tgz#50dc96413d594f995a77905905b05893cd779673" - integrity sha512-n3UGKY4VXwXThEiKrgRAoVPBMqeoPgHVqiHZOanAJCG9nQUL2pLRQirUzl0ioKclHGpGqRgIOkgcIJaIWLpygg== - dependencies: - "@babel/types" "^7.10.4" - -"@babel/helper-plugin-utils@^7.10.4", "@babel/helper-plugin-utils@^7.8.0": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.10.4.tgz#2f75a831269d4f677de49986dff59927533cf375" - integrity sha512-O4KCvQA6lLiMU9l2eawBPMf1xPP8xPfB3iEQw150hOVTqj/rfXz0ThTb4HEzqQfs2Bmo5Ay8BzxfzVtBrr9dVg== - -"@babel/helper-replace-supers@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/helper-replace-supers/-/helper-replace-supers-7.10.4.tgz#d585cd9388ea06e6031e4cd44b6713cbead9e6cf" - integrity sha512-sPxZfFXocEymYTdVK1UNmFPBN+Hv5mJkLPsYWwGBxZAxaWfFu+xqp7b6qWD0yjNuNL2VKc6L5M18tOXUP7NU0A== - dependencies: - "@babel/helper-member-expression-to-functions" "^7.10.4" - "@babel/helper-optimise-call-expression" "^7.10.4" - "@babel/traverse" "^7.10.4" - "@babel/types" "^7.10.4" - -"@babel/helper-simple-access@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/helper-simple-access/-/helper-simple-access-7.10.4.tgz#0f5ccda2945277a2a7a2d3a821e15395edcf3461" - integrity sha512-0fMy72ej/VEvF8ULmX6yb5MtHG4uH4Dbd6I/aHDb/JVg0bbivwt9Wg+h3uMvX+QSFtwr5MeItvazbrc4jtRAXw== - dependencies: - "@babel/template" "^7.10.4" - "@babel/types" "^7.10.4" - -"@babel/helper-split-export-declaration@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.10.4.tgz#2c70576eaa3b5609b24cb99db2888cc3fc4251d1" - integrity sha512-pySBTeoUff56fL5CBU2hWm9TesA4r/rOkI9DyJLvvgz09MB9YtfIYe3iBriVaYNaPe+Alua0vBIOVOLs2buWhg== - dependencies: - "@babel/types" "^7.10.4" - -"@babel/helper-split-export-declaration@^7.11.0": - version "7.11.0" - resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.11.0.tgz#f8a491244acf6a676158ac42072911ba83ad099f" - integrity sha512-74Vejvp6mHkGE+m+k5vHY93FX2cAtrw1zXrZXRlG4l410Nm9PxfEiVTn1PjDPV5SnmieiueY4AFg2xqhNFuuZg== - dependencies: - "@babel/types" "^7.11.0" - -"@babel/helper-validator-identifier@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.10.4.tgz#a78c7a7251e01f616512d31b10adcf52ada5e0d2" - integrity sha512-3U9y+43hz7ZM+rzG24Qe2mufW5KhvFg/NhnNph+i9mgCtdTCtMJuI1TMkrIUiK7Ix4PYlRF9I5dhqaLYA/ADXw== - -"@babel/helpers@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.10.4.tgz#2abeb0d721aff7c0a97376b9e1f6f65d7a475044" - integrity sha512-L2gX/XeUONeEbI78dXSrJzGdz4GQ+ZTA/aazfUsFaWjSe95kiCuOZ5HsXvkiw3iwF+mFHSRUfJU8t6YavocdXA== - dependencies: - "@babel/template" "^7.10.4" - "@babel/traverse" "^7.10.4" - "@babel/types" "^7.10.4" - -"@babel/highlight@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.10.4.tgz#7d1bdfd65753538fabe6c38596cdb76d9ac60143" - integrity sha512-i6rgnR/YgPEQzZZnbTHHuZdlE8qyoBNalD6F+q4vAFlcMEcqmkoG+mPqJYJCo63qPf74+Y1UZsl3l6f7/RIkmA== - dependencies: - "@babel/helper-validator-identifier" "^7.10.4" - chalk "^2.0.0" - js-tokens "^4.0.0" - -"@babel/parser@^7.1.0", "@babel/parser@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.10.4.tgz#9eedf27e1998d87739fb5028a5120557c06a1a64" - integrity sha512-8jHII4hf+YVDsskTF6WuMB3X4Eh+PsUkC2ljq22so5rHvH+T8BzyL94VOdyFLNR8tBSVXOTbNHOKpR4TfRxVtA== - -"@babel/plugin-proposal-nullish-coalescing-operator@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-nullish-coalescing-operator/-/plugin-proposal-nullish-coalescing-operator-7.10.4.tgz#02a7e961fc32e6d5b2db0649e01bf80ddee7e04a" - integrity sha512-wq5n1M3ZUlHl9sqT2ok1T2/MTt6AXE0e1Lz4WzWBr95LsAZ5qDXe4KnFuauYyEyLiohvXFMdbsOTMyLZs91Zlw== - dependencies: - "@babel/helper-plugin-utils" "^7.10.4" - "@babel/plugin-syntax-nullish-coalescing-operator" "^7.8.0" - -"@babel/plugin-proposal-optional-chaining@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-optional-chaining/-/plugin-proposal-optional-chaining-7.10.4.tgz#750f1255e930a1f82d8cdde45031f81a0d0adff7" - integrity sha512-ZIhQIEeavTgouyMSdZRap4VPPHqJJ3NEs2cuHs5p0erH+iz6khB0qfgU8g7UuJkG88+fBMy23ZiU+nuHvekJeQ== +"@babel/code-frame@^7.0.0": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.12.13.tgz#dcfc826beef65e75c50e21d3837d7d95798dd658" + integrity sha512-HV1Cm0Q3ZrpCR93tkWOYiuYIgLxZXZFVG2VgK+MBWjUqZTundupbfx2aXarXuw5Ko5aMcjtJgbSs4vUGBS5v6g== dependencies: - "@babel/helper-plugin-utils" "^7.10.4" - "@babel/plugin-syntax-optional-chaining" "^7.8.0" + "@babel/highlight" "^7.12.13" -"@babel/plugin-syntax-nullish-coalescing-operator@^7.8.0": - version "7.8.3" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-nullish-coalescing-operator/-/plugin-syntax-nullish-coalescing-operator-7.8.3.tgz#167ed70368886081f74b5c36c65a88c03b66d1a9" - integrity sha512-aSff4zPII1u2QD7y+F8oDsz19ew4IGEJg9SVW+bqwpwtfFleiQDMdzA/R+UlWDzfnHFCxxleFT0PMIrR36XLNQ== - dependencies: - "@babel/helper-plugin-utils" "^7.8.0" - -"@babel/plugin-syntax-optional-chaining@^7.8.0": - version "7.8.3" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-optional-chaining/-/plugin-syntax-optional-chaining-7.8.3.tgz#4f69c2ab95167e0180cd5336613f8c5788f7d48a" - integrity sha512-KoK9ErH1MBlCPxV0VANkXW2/dw4vlbGDrFgz8bmUsBGYkFRcbRwMh6cIJubdPrkxRwuGdtCk0v/wPTKbQgBjkg== - dependencies: - "@babel/helper-plugin-utils" "^7.8.0" +"@babel/helper-validator-identifier@^7.12.11": + version "7.12.11" + resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.12.11.tgz#c9a1f021917dcb5ccf0d4e453e399022981fc9ed" + integrity sha512-np/lG3uARFybkoHokJUmf1QfEvRVCPbmQeUQpKow5cQ3xWrV9i3rUHodKDJPQfTVX61qKi+UdYk8kik84n7XOw== -"@babel/plugin-syntax-typescript@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-typescript/-/plugin-syntax-typescript-7.10.4.tgz#2f55e770d3501e83af217d782cb7517d7bb34d25" - integrity sha512-oSAEz1YkBCAKr5Yiq8/BNtvSAPwkp/IyUnwZogd8p+F0RuYQQrLeRUzIQhueQTTBy/F+a40uS7OFKxnkRvmvFQ== +"@babel/highlight@^7.12.13": + version "7.13.10" + resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.13.10.tgz#a8b2a66148f5b27d666b15d81774347a731d52d1" + integrity sha512-5aPpe5XQPzflQrFwL1/QoeHkP2MsA4JCntcXHRhEsdsfPVkvPi2w7Qix4iV7t5S/oC9OodGrggd8aco1g3SZFg== dependencies: - "@babel/helper-plugin-utils" "^7.10.4" + "@babel/helper-validator-identifier" "^7.12.11" + chalk "^2.0.0" + js-tokens "^4.0.0" -"@babel/plugin-transform-typescript@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-typescript/-/plugin-transform-typescript-7.10.4.tgz#8b01cb8d77f795422277cc3fcf45af72bc68ba78" - integrity sha512-3WpXIKDJl/MHoAN0fNkSr7iHdUMHZoppXjf2HJ9/ed5Xht5wNIsXllJXdityKOxeA3Z8heYRb1D3p2H5rfCdPw== +"@babel/runtime@^7.10.4": + version "7.13.17" + resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.13.17.tgz#8966d1fc9593bf848602f0662d6b4d0069e3a7ec" + integrity sha512-NCdgJEelPTSh+FEFylhnP1ylq848l1z9t9N0j1Lfbcw0+KXGjsTvUmkxy+voLLXB5SOKMbLLx4jxYliGrYQseA== dependencies: - "@babel/helper-create-class-features-plugin" "^7.10.4" - "@babel/helper-plugin-utils" "^7.10.4" - "@babel/plugin-syntax-typescript" "^7.10.4" + regenerator-runtime "^0.13.4" -"@babel/runtime@^7.4.4", "@babel/runtime@^7.5.5": +"@babel/runtime@^7.5.5": version "7.10.5" resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.10.5.tgz#303d8bd440ecd5a491eae6117fd3367698674c5c" integrity sha512-otddXKhdNn7d0ptoFRHtMLa8LqDxLYwTjB4nYgM1yy5N6gU/MUf8zqyyLltCH3yAVitBzmwK4us+DD0l/MauAg== dependencies: regenerator-runtime "^0.13.4" -"@babel/runtime@^7.7.2": - version "7.11.2" - resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.11.2.tgz#f549c13c754cc40b87644b9fa9f09a6a95fe0736" - integrity sha512-TeWkU52so0mPtDcaCTxNBI/IHiz0pZgr8VEFqXFtZWpYD08ZB6FaSwVAS8MKRQAP3bYKiVjwysOJgMFY28o6Tw== - dependencies: - regenerator-runtime "^0.13.4" - -"@babel/template@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.10.4.tgz#3251996c4200ebc71d1a8fc405fba940f36ba278" - integrity sha512-ZCjD27cGJFUB6nmCB1Enki3r+L5kJveX9pq1SvAUKoICy6CZ9yD8xO086YXdYhvNjBdnekm4ZnaP5yC8Cs/1tA== - dependencies: - "@babel/code-frame" "^7.10.4" - "@babel/parser" "^7.10.4" - "@babel/types" "^7.10.4" - -"@babel/traverse@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.10.4.tgz#e642e5395a3b09cc95c8e74a27432b484b697818" - integrity sha512-aSy7p5THgSYm4YyxNGz6jZpXf+Ok40QF3aA2LyIONkDHpAcJzDUqlCKXv6peqYUs2gmic849C/t2HKw2a2K20Q== - dependencies: - "@babel/code-frame" "^7.10.4" - "@babel/generator" "^7.10.4" - "@babel/helper-function-name" "^7.10.4" - "@babel/helper-split-export-declaration" "^7.10.4" - "@babel/parser" "^7.10.4" - "@babel/types" "^7.10.4" - debug "^4.1.0" - globals "^11.1.0" - lodash "^4.17.13" - -"@babel/types@^7.0.0", "@babel/types@^7.10.4", "@babel/types@^7.3.0": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.10.4.tgz#369517188352e18219981efd156bfdb199fff1ee" - integrity sha512-UTCFOxC3FsFHb7lkRMVvgLzaRVamXuAs2Tz4wajva4WxtVY82eZeaUBtC2Zt95FU9TiznuC0Zk35tsim8jeVpg== - dependencies: - "@babel/helper-validator-identifier" "^7.10.4" - lodash "^4.17.13" - to-fast-properties "^2.0.0" - -"@babel/types@^7.11.0": - version "7.11.0" - resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.11.0.tgz#2ae6bf1ba9ae8c3c43824e5861269871b206e90d" - integrity sha512-O53yME4ZZI0jO1EVGtF1ePGl0LHirG4P1ibcD80XyzZcKhcMFeCXmh4Xb1ifGBIV233Qg12x4rBfQgA+tmOukA== - dependencies: - "@babel/helper-validator-identifier" "^7.10.4" - lodash "^4.17.19" - to-fast-properties "^2.0.0" - -"@changesets/apply-release-plan@^4.0.0": - version "4.0.0" - resolved "https://registry.yarnpkg.com/@changesets/apply-release-plan/-/apply-release-plan-4.0.0.tgz#e78efb56a4e459a8dab814ba43045f2ace0f27c9" - integrity sha512-MrcUd8wIlQ4S/PznzqJVsmnEpUGfPEkCGF54iqt8G05GEqi/zuxpoTfebcScpj5zeiDyxFIcA9RbeZ3pvJJxoA== +"@changesets/apply-release-plan@^5.0.0": + version "5.0.0" + resolved "https://registry.yarnpkg.com/@changesets/apply-release-plan/-/apply-release-plan-5.0.0.tgz#11bf168acecbf4cfa2b0e6425160bac5ceeec1c3" + integrity sha512-SE+5nPNSKUyUociPnAvnjYSVF+diciEhX9ZHSqKWMlydswCDjiaq9gz67qwWCmwgEgEOz0TS7VrQBoOlzbitvA== dependencies: - "@babel/runtime" "^7.4.4" - "@changesets/config" "^1.2.0" + "@babel/runtime" "^7.10.4" + "@changesets/config" "^1.6.0" "@changesets/get-version-range-type" "^0.3.2" - "@changesets/git" "^1.0.5" - "@changesets/types" "^3.1.0" + "@changesets/git" "^1.1.1" + "@changesets/types" "^4.0.0" "@manypkg/get-packages" "^1.0.1" + detect-indent "^6.0.0" fs-extra "^7.0.1" lodash.startcase "^4.4.0" outdent "^0.5.0" - prettier "^1.18.2" + prettier "^1.19.1" resolve-from "^5.0.0" semver "^5.4.1" -"@changesets/assemble-release-plan@^3.0.0": - version "3.0.0" - resolved "https://registry.yarnpkg.com/@changesets/assemble-release-plan/-/assemble-release-plan-3.0.0.tgz#23c280b0ea352003302b0c262b8dadb8bda517ed" - integrity sha512-TvcqUhNhKoqwE+L8dFtcwwAmos4+fqwmSkOWP3TSjw7K/inz2wjC46bA7IFtbx2hrwEq1iG0RCweQZTS2vrx1w== +"@changesets/assemble-release-plan@^5.0.0": + version "5.0.0" + resolved "https://registry.yarnpkg.com/@changesets/assemble-release-plan/-/assemble-release-plan-5.0.0.tgz#3e57405e5c375e2d933f62e74d1874915e60cd61" + integrity sha512-LElDXTCBUkPSmdXlCisoUWw2paX48snatBmw/hKnGiSvnyZqdTIylLojAGQWG0/vOO9v3s/DvJ4hdagIquxJjg== dependencies: - "@babel/runtime" "^7.4.4" + "@babel/runtime" "^7.10.4" "@changesets/errors" "^0.1.4" - "@changesets/get-dependents-graph" "^1.1.3" - "@changesets/types" "^3.1.0" + "@changesets/get-dependents-graph" "^1.2.1" + "@changesets/types" "^4.0.0" "@manypkg/get-packages" "^1.0.1" semver "^5.4.1" -"@changesets/cli@^2.9.2": - version "2.9.2" - resolved "https://registry.yarnpkg.com/@changesets/cli/-/cli-2.9.2.tgz#895343c5e61ca6072d3faa3798be703ea230e518" - integrity sha512-1L9391G4YlofC1UbfwmBrsefwC03mJHK5Cn8oSozhQJMbRlCJLBJiOn5PHFruVMFcvACGER3R+2Yv62pGKneDw== +"@changesets/cli@^2.16.0": + version "2.16.0" + resolved "https://registry.yarnpkg.com/@changesets/cli/-/cli-2.16.0.tgz#9f794005d0503efba5e348b929821a1732fd0f0d" + integrity sha512-VFkXSyyk/WRjjUoBI7g7cDy09qBjPbBQOloPMEshTzMo/NY9muWHl2yB/FSSkV/6PxGimPtJ7aEJPYfk8HCfXw== dependencies: - "@babel/runtime" "^7.4.4" - "@changesets/apply-release-plan" "^4.0.0" - "@changesets/assemble-release-plan" "^3.0.0" - "@changesets/config" "^1.3.0" + "@babel/runtime" "^7.10.4" + "@changesets/apply-release-plan" "^5.0.0" + "@changesets/assemble-release-plan" "^5.0.0" + "@changesets/config" "^1.6.0" "@changesets/errors" "^0.1.4" - "@changesets/get-dependents-graph" "^1.1.3" - "@changesets/get-release-plan" "^2.0.0" - "@changesets/git" "^1.0.5" + "@changesets/get-dependents-graph" "^1.2.1" + "@changesets/get-release-plan" "^3.0.0" + "@changesets/git" "^1.1.1" "@changesets/logger" "^0.0.5" - "@changesets/pre" "^1.0.4" - "@changesets/read" "^0.4.6" - "@changesets/types" "^3.1.0" - "@changesets/write" "^0.1.3" + "@changesets/pre" "^1.0.6" + "@changesets/read" "^0.4.7" + "@changesets/types" "^4.0.0" + "@changesets/write" "^0.1.4" "@manypkg/get-packages" "^1.0.1" "@types/semver" "^6.0.0" boxen "^1.3.0" chalk "^2.1.0" enquirer "^2.3.0" + external-editor "^3.1.0" fs-extra "^7.0.1" human-id "^1.0.2" is-ci "^2.0.0" - meow "^5.0.0" + meow "^6.0.0" outdent "^0.5.0" p-limit "^2.2.0" preferred-pm "^3.0.0" semver "^5.4.1" spawndamnit "^2.0.0" term-size "^2.1.0" - tty-table "^2.7.0" + tty-table "^2.8.10" -"@changesets/config@^1.2.0", "@changesets/config@^1.3.0": - version "1.3.0" - resolved "https://registry.yarnpkg.com/@changesets/config/-/config-1.3.0.tgz#82fcbf572b00ba16636be9ea45167983f1fc203b" - integrity sha512-IeAHmN5kI7OywBUNJXsk/v4vcXDDscwgTe/K5D3FSng5QTvzbgiMAe5K1iwBxBvuT4u/33n89kxSJdg4TTTFfA== +"@changesets/config@^1.6.0": + version "1.6.0" + resolved "https://registry.yarnpkg.com/@changesets/config/-/config-1.6.0.tgz#2cd9426b9d4212534d2b31c51de43280b76d3df4" + integrity sha512-vMY/OpMFSDC2crDKb5Nq2kMX9hozcXL4dY5Rr+a1JQ044Rz+jqjJPpdTP2yQ+j7qmeGcUTvwjJoEMeekYwfqhg== dependencies: "@changesets/errors" "^0.1.4" - "@changesets/get-dependents-graph" "^1.1.3" + "@changesets/get-dependents-graph" "^1.2.1" "@changesets/logger" "^0.0.5" - "@changesets/types" "^3.1.0" + "@changesets/types" "^4.0.0" "@manypkg/get-packages" "^1.0.1" fs-extra "^7.0.1" + micromatch "^4.0.2" "@changesets/errors@^0.1.4": version "0.1.4" @@ -354,28 +124,28 @@ dependencies: extendable-error "^0.1.5" -"@changesets/get-dependents-graph@^1.1.3": - version "1.1.3" - resolved "https://registry.yarnpkg.com/@changesets/get-dependents-graph/-/get-dependents-graph-1.1.3.tgz#da959c43ce98f3a990a6b8d9c1f894bcc1b629c7" - integrity sha512-cTbySXwSv9yWp4Pp5R/b5Qv23wJgFaFCqUbsI3IJ2pyPl0vMaODAZS8NI1nNK2XSxGIg1tw+dWNSR4PlrKBSVQ== +"@changesets/get-dependents-graph@^1.2.1": + version "1.2.1" + resolved "https://registry.yarnpkg.com/@changesets/get-dependents-graph/-/get-dependents-graph-1.2.1.tgz#462908693dc3a354622e43f85a764b74b5bb53af" + integrity sha512-vJOibo9SkqhVbgfq5AHIlQ7tzkYQIXh3tPAnlNLy2bPZsU+SByd74GaxHYWt1zOBlncU25WKrIM6J7XBB+GVUg== dependencies: - "@changesets/types" "^3.0.0" + "@changesets/types" "^4.0.0" "@manypkg/get-packages" "^1.0.1" chalk "^2.1.0" fs-extra "^7.0.1" semver "^5.4.1" -"@changesets/get-release-plan@^2.0.0": - version "2.0.0" - resolved "https://registry.yarnpkg.com/@changesets/get-release-plan/-/get-release-plan-2.0.0.tgz#570dbd0abcdd4169a73e8332ec139a01130f3b72" - integrity sha512-MHbgXMhkfWhXH1zUefrdtQ8IR+H46lAcKthKjptV28k0qGEcDk7KriYLukJ6BNkWiZkkZ/aycaivbNDclF9zaw== - dependencies: - "@babel/runtime" "^7.4.4" - "@changesets/assemble-release-plan" "^3.0.0" - "@changesets/config" "^1.2.0" - "@changesets/pre" "^1.0.4" - "@changesets/read" "^0.4.6" - "@changesets/types" "^3.1.0" +"@changesets/get-release-plan@^3.0.0": + version "3.0.0" + resolved "https://registry.yarnpkg.com/@changesets/get-release-plan/-/get-release-plan-3.0.0.tgz#55efc01db2e24bd7a88e703956eb2f6c4a79054f" + integrity sha512-7VLiqpcWZyjwIXYgkubBC/9cdwqUJEhLMRT9/Y9+ctHqrpsXmJg15QQPTOh3HT9yGN5fJPL1WwuZkc1HXUhK0g== + dependencies: + "@babel/runtime" "^7.10.4" + "@changesets/assemble-release-plan" "^5.0.0" + "@changesets/config" "^1.6.0" + "@changesets/pre" "^1.0.6" + "@changesets/read" "^0.4.7" + "@changesets/types" "^4.0.0" "@manypkg/get-packages" "^1.0.1" "@changesets/get-version-range-type@^0.3.2": @@ -383,14 +153,14 @@ resolved "https://registry.yarnpkg.com/@changesets/get-version-range-type/-/get-version-range-type-0.3.2.tgz#8131a99035edd11aa7a44c341cbb05e668618c67" integrity sha512-SVqwYs5pULYjYT4op21F2pVbcrca4qA/bAA3FmFXKMN7Y+HcO8sbZUTx3TAy2VXulP2FACd1aC7f2nTuqSPbqg== -"@changesets/git@^1.0.5": - version "1.0.5" - resolved "https://registry.yarnpkg.com/@changesets/git/-/git-1.0.5.tgz#e392128a13b210c482324d0d329029a3f7613b10" - integrity sha512-MgacjTRCrfFCffvoipqbtHSENydaO+HDR6z+gDQ49Gl2kHIat0iIazL1TBfEuW8H4eGCay+Naz/x6412ucUOTw== +"@changesets/git@^1.1.1": + version "1.1.1" + resolved "https://registry.yarnpkg.com/@changesets/git/-/git-1.1.1.tgz#f444d3ff3604acb6949560656c9ef330485a5fa3" + integrity sha512-Z12TcKwgU33YE3r76cyU+X81RchOXljDZ5s3G2u0Zd+ODyrwlDb91IO55+6R0Ha6ouPz8ioont0gA70c1RFngg== dependencies: - "@babel/runtime" "^7.4.4" + "@babel/runtime" "^7.10.4" "@changesets/errors" "^0.1.4" - "@changesets/types" "^3.0.0" + "@changesets/types" "^4.0.0" "@manypkg/get-packages" "^1.0.1" is-subdir "^1.1.1" spawndamnit "^2.0.0" @@ -402,54 +172,62 @@ dependencies: chalk "^2.1.0" -"@changesets/parse@^0.3.6": - version "0.3.6" - resolved "https://registry.yarnpkg.com/@changesets/parse/-/parse-0.3.6.tgz#8c2c8480fc07d2db2c37469d4a8df10906a989c6" - integrity sha512-0XPd/es9CfogI7XIqDr7I2mWzm++xX2s9GZsij3GajPYd7ouEsgJyNatPooxNtqj6ZepkiD6uqlqbeBUyj/A0Q== +"@changesets/parse@^0.3.8": + version "0.3.8" + resolved "https://registry.yarnpkg.com/@changesets/parse/-/parse-0.3.8.tgz#0bb244eccb35cb301168f85684bb03389c59341d" + integrity sha512-0S7Dc7XbMOKamBtd48vVuWL2aFZyaglw6lJsXNddn9forFf8oMKMmdyJ/HQPyeEChDDOhDF1/ya7m/zpt4Dk4w== dependencies: - "@changesets/types" "^3.0.0" + "@changesets/types" "^4.0.0" js-yaml "^3.13.1" -"@changesets/pre@^1.0.4": - version "1.0.5" - resolved "https://registry.yarnpkg.com/@changesets/pre/-/pre-1.0.5.tgz#91e5e3b31b4a85ce37de72f6511a786f62f29b51" - integrity sha512-p43aAQY3aijhDnBLCriPao5YArlRjD4mSHRJq9PsBhljVLWqQQXcn6seSd77d+bD1tATLhB8tQ2eYoxMtMydXQ== +"@changesets/pre@^1.0.6": + version "1.0.6" + resolved "https://registry.yarnpkg.com/@changesets/pre/-/pre-1.0.6.tgz#45700cf18274b35b2296000befe7fe4df8ff046f" + integrity sha512-ZwFFQLjhTmA4hj8+Cf9pm6nD9Tp+AiBz1wJLaGum4Ae1fPXMwDnJfHknFUTytqZBlC0gHkiGSj6QkUuetWvckg== dependencies: - "@babel/runtime" "^7.4.4" + "@babel/runtime" "^7.10.4" "@changesets/errors" "^0.1.4" - "@changesets/types" "^3.0.0" + "@changesets/types" "^4.0.0" "@manypkg/get-packages" "^1.0.1" fs-extra "^7.0.1" -"@changesets/read@^0.4.6": - version "0.4.6" - resolved "https://registry.yarnpkg.com/@changesets/read/-/read-0.4.6.tgz#1c03e709a870a070fc95490ffa696297d23458f7" - integrity sha512-rOd8dsF/Lgyy2SYlDalb3Ts/meDI2AcKPXYhSXIW3k6+ZLlj6Pt+nmgV5Ut8euyH7loibklNTDemfvMffF4xig== +"@changesets/read@^0.4.7": + version "0.4.7" + resolved "https://registry.yarnpkg.com/@changesets/read/-/read-0.4.7.tgz#5a32ae7092330fba31eaec4c83321bb936605766" + integrity sha512-E70QrYQpSCMF0nC0dlPU7i6A9zht+8zkQczrKMbOUwDVrfidcvgojxfuJSQbzptYSb9OKYh8GOLd+bsq9+uO9Q== dependencies: - "@babel/runtime" "^7.4.4" - "@changesets/git" "^1.0.5" + "@babel/runtime" "^7.10.4" + "@changesets/git" "^1.1.1" "@changesets/logger" "^0.0.5" - "@changesets/parse" "^0.3.6" - "@changesets/types" "^3.0.0" + "@changesets/parse" "^0.3.8" + "@changesets/types" "^4.0.0" chalk "^2.1.0" fs-extra "^7.0.1" p-filter "^2.1.0" -"@changesets/types@^3.0.0", "@changesets/types@^3.1.0": - version "3.1.0" - resolved "https://registry.yarnpkg.com/@changesets/types/-/types-3.1.0.tgz#68957af45a0be29f0908e20a990ecf382282e1f1" - integrity sha512-czOfaaxr5aGnNwVRgWr3n2CKoc3iRTfrHM4wUHQ+rBlLKKk9NzGwZ2EPsXkp4CUw4hWHGEOi8hdeIfDTWKrWgg== +"@changesets/types@^4.0.0": + version "4.0.0" + resolved "https://registry.yarnpkg.com/@changesets/types/-/types-4.0.0.tgz#635f804546b0a96ecc0ca3f26403a6782a3dc938" + integrity sha512-whLmPx2wgJRoOtxVZop+DJ71z1gTSkij7osiHgN+pe//FiE6bb4ffvBBb0rACs2cUPfAkWxgSPzqkECgKS1jvQ== -"@changesets/write@^0.1.3": - version "0.1.3" - resolved "https://registry.yarnpkg.com/@changesets/write/-/write-0.1.3.tgz#00ae575af50274773d7493e77fb96838a08ad8ad" - integrity sha512-q79rbwlVmTNKP9O6XxcMDj81CEOn/kQHbTFdRleW0tFUv98S1EyEAE9vLPPzO6WnQipHnaozxB1zMhHy0aQn8Q== +"@changesets/write@^0.1.4": + version "0.1.4" + resolved "https://registry.yarnpkg.com/@changesets/write/-/write-0.1.4.tgz#5828ecc70c48d0e8696c5f13fe06b730cdfde6f2" + integrity sha512-uco+vS3mo2JqflLciIU707har+6AEFOeP8pgu3vVC1M2WcKukQgR1KylHFqZJxKQWahf8mQnuUSbgR4yJQuhmA== dependencies: - "@babel/runtime" "^7.4.4" - "@changesets/types" "^3.0.0" + "@babel/runtime" "^7.10.4" + "@changesets/types" "^4.0.0" fs-extra "^7.0.1" human-id "^1.0.2" - prettier "^1.18.2" + prettier "^1.19.1" + +"@dsherret/to-absolute-glob@^2.0.2": + version "2.0.2" + resolved "https://registry.yarnpkg.com/@dsherret/to-absolute-glob/-/to-absolute-glob-2.0.2.tgz#1f6475dc8bd974cea07a2daf3864b317b1dd332c" + integrity sha1-H2R13IvZdM6gei2vOGSzF7HdMyw= + dependencies: + is-absolute "^1.0.0" + is-negated-glob "^1.0.0" "@manypkg/find-root@^1.1.0": version "1.1.0" @@ -493,35 +271,6 @@ "@nodelib/fs.scandir" "2.1.3" fastq "^1.6.0" -"@rollup/plugin-babel@^5.2.0": - version "5.2.0" - resolved "https://registry.yarnpkg.com/@rollup/plugin-babel/-/plugin-babel-5.2.0.tgz#b87556d61ed108b4eaf9d18b5323965adf8d9bee" - integrity sha512-CPABsajaKjINgBQ3it+yMnfVO3ibsrMBxRzbUOUw2cL1hsZJ7aogU8mgglQm3S2hHJgjnAmxPz0Rq7DVdmHsTw== - dependencies: - "@babel/helper-module-imports" "^7.10.4" - "@rollup/pluginutils" "^3.1.0" - -"@rollup/plugin-node-resolve@^9.0.0": - version "9.0.0" - resolved "https://registry.yarnpkg.com/@rollup/plugin-node-resolve/-/plugin-node-resolve-9.0.0.tgz#39bd0034ce9126b39c1699695f440b4b7d2b62e6" - integrity sha512-gPz+utFHLRrd41WMP13Jq5mqqzHL3OXrfj3/MkSyB6UBIcuNt9j60GCbarzMzdf1VHFpOxfQh/ez7wyadLMqkg== - dependencies: - "@rollup/pluginutils" "^3.1.0" - "@types/resolve" "1.17.1" - builtin-modules "^3.1.0" - deepmerge "^4.2.2" - is-module "^1.0.0" - resolve "^1.17.0" - -"@rollup/pluginutils@^3.1.0": - version "3.1.0" - resolved "https://registry.yarnpkg.com/@rollup/pluginutils/-/pluginutils-3.1.0.tgz#706b4524ee6dc8b103b3c995533e5ad680c02b9b" - integrity sha512-GksZ6pr6TpIjHm8h9lSQ8pi8BE9VeubNT0OMJ3B5uZJ8pz73NPiqOtCog/x2/QzM1ENChPKxMDhiQuRHsqc+lg== - dependencies: - "@types/estree" "0.0.39" - estree-walker "^1.0.1" - picomatch "^2.2.2" - "@sindresorhus/is@^0.14.0": version "0.14.0" resolved "https://registry.yarnpkg.com/@sindresorhus/is/-/is-0.14.0.tgz#9fb3a3cf3132328151f353de4632e01e52102bea" @@ -534,56 +283,22 @@ dependencies: defer-to-connect "^1.0.1" -"@types/babel-plugin-macros@^2.8.2": - version "2.8.2" - resolved "https://registry.yarnpkg.com/@types/babel-plugin-macros/-/babel-plugin-macros-2.8.2.tgz#4c56035db90b3117bc22b02412b83ed264dc0874" - integrity sha512-71QJGL4k1PnJ4qcTb86Axjbs9yyGD0vQHjZY5/HDcqUvwZDL3JYjF7Agh/E7xJQvQGZ7cW+xtr1XpTyKUR7aRw== +"@ts-morph/common@~0.8.0": + version "0.8.0" + resolved "https://registry.yarnpkg.com/@ts-morph/common/-/common-0.8.0.tgz#ae7b292df8258040465c50b378108ec8f09a9516" + integrity sha512-YbjWiMXLMKxWxcMqP47nwZVWVBwoF5B65dtRz0lya2LetjldAPxTxRbRo1n4Iszr2tSvzXeaa+f1AbULmfc5uA== dependencies: - "@types/babel__core" "*" - -"@types/babel__core@*", "@types/babel__core@^7.1.9": - version "7.1.9" - resolved "https://registry.yarnpkg.com/@types/babel__core/-/babel__core-7.1.9.tgz#77e59d438522a6fb898fa43dc3455c6e72f3963d" - integrity sha512-sY2RsIJ5rpER1u3/aQ8OFSI7qGIy8o1NEEbgb2UaJcvOtXOMpd39ko723NBpjQFg9SIX7TXtjejZVGeIMLhoOw== - dependencies: - "@babel/parser" "^7.1.0" - "@babel/types" "^7.0.0" - "@types/babel__generator" "*" - "@types/babel__template" "*" - "@types/babel__traverse" "*" - -"@types/babel__generator@*": - version "7.6.1" - resolved "https://registry.yarnpkg.com/@types/babel__generator/-/babel__generator-7.6.1.tgz#4901767b397e8711aeb99df8d396d7ba7b7f0e04" - integrity sha512-bBKm+2VPJcMRVwNhxKu8W+5/zT7pwNEqeokFOmbvVSqGzFneNxYcEBro9Ac7/N9tlsaPYnZLK8J1LWKkMsLAew== - dependencies: - "@babel/types" "^7.0.0" - -"@types/babel__template@*": - version "7.0.2" - resolved "https://registry.yarnpkg.com/@types/babel__template/-/babel__template-7.0.2.tgz#4ff63d6b52eddac1de7b975a5223ed32ecea9307" - integrity sha512-/K6zCpeW7Imzgab2bLkLEbz0+1JlFSrUMdw7KoIIu+IUdu51GWaBZpd3y1VXGVXzynvGa4DaIaxNZHiON3GXUg== - dependencies: - "@babel/parser" "^7.1.0" - "@babel/types" "^7.0.0" - -"@types/babel__traverse@*": - version "7.0.12" - resolved "https://registry.yarnpkg.com/@types/babel__traverse/-/babel__traverse-7.0.12.tgz#22f49a028e69465390f87bb103ebd61bd086b8f5" - integrity sha512-t4CoEokHTfcyfb4hUaF9oOHu9RmmNWnm1CP0YmMqOOfClKascOmvlEM736vlqeScuGvBDsHkf8R2INd4DWreQA== - dependencies: - "@babel/types" "^7.3.0" + "@dsherret/to-absolute-glob" "^2.0.2" + fast-glob "^3.2.5" + is-negated-glob "^1.0.0" + mkdirp "^1.0.4" + multimatch "^5.0.0" "@types/color-name@^1.1.1": version "1.1.1" resolved "https://registry.yarnpkg.com/@types/color-name/-/color-name-1.1.1.tgz#1c1261bbeaa10a8055bbc5d8ab84b7b2afc846a0" integrity sha512-rr+OQyAjxze7GgWrSaJwydHStIhHq2lvY3BOC2Mj7KnzI7XK0Uw1TOOdI9lDoajEbSWLiYgoo4f1R51erQfhPQ== -"@types/estree@0.0.39": - version "0.0.39" - resolved "https://registry.yarnpkg.com/@types/estree/-/estree-0.0.39.tgz#e177e699ee1b8c22d23174caaa7422644389509f" - integrity sha512-EYNwp3bU+98cpU4lAWYYL7Zz+2gryWH1qbdDTidVd6hkiR6weksdbMadyXKXNPEkQFhXM+hVO9ZygomHXp+AIw== - "@types/gaze@^1.1.0": version "1.1.0" resolved "https://registry.yarnpkg.com/@types/gaze/-/gaze-1.1.0.tgz#21d800688eba9f5fab955648b7946083c0074a9b" @@ -604,7 +319,7 @@ dependencies: handlebars ">=4.1.0" -"@types/minimatch@*": +"@types/minimatch@*", "@types/minimatch@^3.0.3": version "3.0.3" resolved "https://registry.yarnpkg.com/@types/minimatch/-/minimatch-3.0.3.tgz#3dca0e3f33b200fc7d1139c0cd96c1268cadfd9d" integrity sha512-tHq6qdbT9U1IRSGf14CL0pUlULksvY9OZ+5eEgl1N7t+OA3tGvNpxJCzuKQlsNgCVwbAs670L1vcVQi8j9HjnA== @@ -629,17 +344,10 @@ resolved "https://registry.yarnpkg.com/@types/node/-/node-14.0.14.tgz#24a0b5959f16ac141aeb0c5b3cd7a15b7c64cbce" integrity sha512-syUgf67ZQpaJj01/tRTknkMNoBBLWJOBODF0Zm4NrXmiSuxjymFrxnTu1QVYRubhVkRcZLYZG8STTwJRdVm/WQ== -"@types/parse-json@^4.0.0": - version "4.0.0" - resolved "https://registry.yarnpkg.com/@types/parse-json/-/parse-json-4.0.0.tgz#2f8bb441434d163b35fb8ffdccd7138927ffb8c0" - integrity sha512-//oorEZjL6sbPcKUaCdIGlIUeH26mgzimjBB77G6XRgnDl/L5wOnpyBGRe/Mmf5CVW3PwEBE1NjiMZ/ssFh4wA== - -"@types/resolve@1.17.1": - version "1.17.1" - resolved "https://registry.yarnpkg.com/@types/resolve/-/resolve-1.17.1.tgz#3afd6ad8967c77e4376c598a82ddd58f46ec45d6" - integrity sha512-yy7HuzQhj0dhGpD8RLXSZWEkLsV9ibvxvi6EiJ3bkqLAO1RGo0WbkWQiwpRlSFymTJRz0d3k5LM3kkx8ArDbLw== - dependencies: - "@types/node" "*" +"@types/normalize-package-data@^2.4.0": + version "2.4.0" + resolved "https://registry.yarnpkg.com/@types/normalize-package-data/-/normalize-package-data-2.4.0.tgz#e486d0d97396d79beedd0a6e33f4534ff6b4973e" + integrity sha512-f5j5b/Gf71L+dbqxIpQ4Z2WlmI/mPJ0fOkGGmFgtb6sAu97EPczzbS3/tJKxmcYDj55OX6ssqwDAWOHIYDRDGA== "@types/rimraf@^3.0.0": version "3.0.0" @@ -968,10 +676,10 @@ arr-union@^3.1.0: resolved "https://registry.yarnpkg.com/arr-union/-/arr-union-3.1.0.tgz#e39b09aea9def866a8f206e288af63919bae39c4" integrity sha1-45sJrqne+Gao8gbiiK9jkZuuOcQ= -array-find-index@^1.0.1: - version "1.0.2" - resolved "https://registry.yarnpkg.com/array-find-index/-/array-find-index-1.0.2.tgz#df010aa1287e164bbda6f9723b0a96a1ec4187a1" - integrity sha1-3wEKoSh+Fku9pvlyOwqWoexBh6E= +array-differ@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/array-differ/-/array-differ-3.0.0.tgz#3cbb3d0f316810eafcc47624734237d6aee4ae6b" + integrity sha512-THtfYS6KtME/yIAhKjZ2ul7XI96lQGHRputJQHO80LAWQnuGP4iCIN8vdMRboGbIEYBwU33q8Tch1os2+X0kMg== array-sort@^0.1.4: version "0.1.4" @@ -997,6 +705,11 @@ arrify@^1.0.1: resolved "https://registry.yarnpkg.com/arrify/-/arrify-1.0.1.tgz#898508da2226f380df904728456849c1501a4b0d" integrity sha1-iYUI2iIm84DfkEcoRWhJwVAaSw0= +arrify@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/arrify/-/arrify-2.0.1.tgz#c9655e9331e0abcd588d2a7cad7e9956f66701fa" + integrity sha512-3duEwti880xqi4eAMN8AyR4a0ByT90zoYdLlevfrvU43vb0YZwZVfxOgxWrLXXXpyugL0hNZc9G6BiB5B3nUug== + assign-symbols@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/assign-symbols/-/assign-symbols-1.0.0.tgz#59667f41fadd4f20ccbc2bb96b8d4f7f78ec0367" @@ -1014,15 +727,6 @@ autolinker@~0.28.0: dependencies: gulp-header "^1.7.1" -babel-plugin-macros@^2.8.0: - version "2.8.0" - resolved "https://registry.yarnpkg.com/babel-plugin-macros/-/babel-plugin-macros-2.8.0.tgz#0f958a7cc6556b1e65344465d99111a1e5e10138" - integrity sha512-SEP5kJpfGYqYKpBrj5XU3ahw5p5GOHJ0U5ssOSQ/WBVdwkD2Dzlce95exQTs3jOVWPPKLBN2rlEWkCK7dSmLvg== - dependencies: - "@babel/runtime" "^7.7.2" - cosmiconfig "^6.0.0" - resolve "^1.12.0" - balanced-match@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.0.tgz#89b4d199ab2bee49de164ea02b89ce462d71b767" @@ -1123,11 +827,6 @@ buffer-from@^1.0.0: resolved "https://registry.yarnpkg.com/buffer-from/-/buffer-from-1.1.1.tgz#32713bc028f75c02fdb710d7c7bcec1f2c6070ef" integrity sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A== -builtin-modules@^3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/builtin-modules/-/builtin-modules-3.1.0.tgz#aad97c15131eb76b65b50ef208e7584cd76a7484" - integrity sha512-k0KL0aWZuBt2lrxrcASWDfwOLMnodeQjodT/1SxEQAXsHANgo6ZC/VEaSEHCXt7aSTZ4/4H5LKa+tBXmW7Vtvw== - cache-base@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/cache-base/-/cache-base-1.0.1.tgz#0a7f46416831c8b662ee36fe4e7c59d76f666ab2" @@ -1156,21 +855,16 @@ cacheable-request@^6.0.0: normalize-url "^4.1.0" responselike "^1.0.2" -callsites@^3.0.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/callsites/-/callsites-3.1.0.tgz#b3630abd8943432f54b3f0519238e33cd7df2f73" - integrity sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ== - -camelcase-keys@^4.0.0: - version "4.2.0" - resolved "https://registry.yarnpkg.com/camelcase-keys/-/camelcase-keys-4.2.0.tgz#a2aa5fb1af688758259c32c141426d78923b9b77" - integrity sha1-oqpfsa9oh1glnDLBQUJteJI7m3c= +camelcase-keys@^6.2.2: + version "6.2.2" + resolved "https://registry.yarnpkg.com/camelcase-keys/-/camelcase-keys-6.2.2.tgz#5e755d6ba51aa223ec7d3d52f25778210f9dc3c0" + integrity sha512-YrwaA0vEKazPBkn0ipTiMpSajYDSe+KjQfrjhcBMxJt/znbvlHd8Pw/Vamaz5EB4Wfhs3SUR3Z9mwRu/P3s3Yg== dependencies: - camelcase "^4.1.0" - map-obj "^2.0.0" - quick-lru "^1.0.0" + camelcase "^5.3.1" + map-obj "^4.0.0" + quick-lru "^4.0.1" -camelcase@^4.0.0, camelcase@^4.1.0: +camelcase@^4.0.0: version "4.1.0" resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-4.1.0.tgz#d545635be1e33c542649c69173e5de6acfae34dd" integrity sha1-1UVjW+HjPFQmScaRc+Xeas+uNN0= @@ -1197,6 +891,11 @@ chalk@^3.0.0: ansi-styles "^4.1.0" supports-color "^7.1.0" +chardet@^0.7.0: + version "0.7.0" + resolved "https://registry.yarnpkg.com/chardet/-/chardet-0.7.0.tgz#90094849f0937f2eedc2425d0d28a9e5f0cbad9e" + integrity sha512-mT8iDcrh03qDGRRmoA2hmBJnxpllMR+0/0qlzjqZES6NdiWDcZkCNAk4rPFZ9Q85r27unkiNNg8ZOiwZXBHwcA== + chokidar@^3.2.2: version "3.4.2" resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-3.4.2.tgz#38dc8e658dec3809741eb3ef7bb0a47fe424232d" @@ -1273,6 +972,11 @@ clone@^1.0.2: resolved "https://registry.yarnpkg.com/clone/-/clone-1.0.4.tgz#da309cc263df15994c688ca902179ca3c7cd7c7e" integrity sha1-2jCcwmPfFZlMaIypAheco8fNfH4= +code-block-writer@^10.1.1: + version "10.1.1" + resolved "https://registry.yarnpkg.com/code-block-writer/-/code-block-writer-10.1.1.tgz#ad5684ed4bfb2b0783c8b131281ae84ee640a42f" + integrity sha512-67ueh2IRGst/51p0n6FvPrnRjAGHY5F8xdjkgrYE7DDzpJe6qA07RYQ9VcoUeo5ATOjSOiWpSL3SWBRRbempMw== + collection-visit@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/collection-visit/-/collection-visit-1.0.0.tgz#4bc0373c164bc3291b4d368c829cf1a80a59dca0" @@ -1339,13 +1043,6 @@ configstore@^5.0.1: write-file-atomic "^3.0.0" xdg-basedir "^4.0.0" -convert-source-map@^1.7.0: - version "1.7.0" - resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.7.0.tgz#17a2cb882d7f77d3490585e2ce6c524424a3a442" - integrity sha512-4FJkXzKXEDB1snCFZlLP4gpC3JILicCpGbzG9f9G7tGqGCzETQ2hWPrcinA9oU4wtf2biUaEH5065UnMeR33oA== - dependencies: - safe-buffer "~5.1.1" - copy-descriptor@^0.1.0: version "0.1.1" resolved "https://registry.yarnpkg.com/copy-descriptor/-/copy-descriptor-0.1.1.tgz#676f6eb3c39997c2ee1ac3a924fd6124748f578d" @@ -1356,17 +1053,6 @@ core-util-is@~1.0.0: resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.2.tgz#b5fd54220aa2bc5ab57aab7140c940754503c1a7" integrity sha1-tf1UIgqivFq1eqtxQMlAdUUDwac= -cosmiconfig@^6.0.0: - version "6.0.0" - resolved "https://registry.yarnpkg.com/cosmiconfig/-/cosmiconfig-6.0.0.tgz#da4fee853c52f6b1e6935f41c1a2fc50bd4a9982" - integrity sha512-xb3ZL6+L8b9JLLCx3ZdoZy4+2ECphCMo2PwqgP1tlfVq6M6YReyzBJtvWWtbDSpNr9hn96pkCiZqUcFEc+54Qg== - dependencies: - "@types/parse-json" "^4.0.0" - import-fresh "^3.1.0" - parse-json "^5.0.0" - path-type "^4.0.0" - yaml "^1.7.2" - create-frame@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/create-frame/-/create-frame-1.0.0.tgz#8b95f2691e3249b6080443e33d0bad9f8f6975aa" @@ -1416,13 +1102,6 @@ csv@^5.3.1: csv-stringify "^5.3.6" stream-transform "^2.0.1" -currently-unhandled@^0.4.1: - version "0.4.1" - resolved "https://registry.yarnpkg.com/currently-unhandled/-/currently-unhandled-0.4.1.tgz#988df33feab191ef799a61369dd76c17adf957ea" - integrity sha1-mI3zP+qxke95mmE2nddsF635V+o= - dependencies: - array-find-index "^1.0.1" - date.js@^0.3.1: version "0.3.3" resolved "https://registry.yarnpkg.com/date.js/-/date.js-0.3.3.tgz#ef1e92332f507a638795dbb985e951882e50bbda" @@ -1444,13 +1123,6 @@ debug@^3.2.6: dependencies: ms "^2.1.1" -debug@^4.1.0: - version "4.1.1" - resolved "https://registry.yarnpkg.com/debug/-/debug-4.1.1.tgz#3b72260255109c6b589cee050f1d516139664791" - integrity sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw== - dependencies: - ms "^2.1.1" - debug@~3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/debug/-/debug-3.1.0.tgz#5bb5a0672628b64149566ba16819e61518c67261" @@ -1458,7 +1130,7 @@ debug@~3.1.0: dependencies: ms "2.0.0" -decamelize-keys@^1.0.0: +decamelize-keys@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/decamelize-keys/-/decamelize-keys-1.1.0.tgz#d171a87933252807eb3cb61dc1c1445d078df2d9" integrity sha1-0XGoeTMlKAfrPLYdwcFEXQeN8tk= @@ -1488,11 +1160,6 @@ deep-extend@^0.6.0: resolved "https://registry.yarnpkg.com/deep-extend/-/deep-extend-0.6.0.tgz#c4fa7c95404a17a9c3e8ca7e1537312b736330ac" integrity sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA== -deepmerge@^4.2.2: - version "4.2.2" - resolved "https://registry.yarnpkg.com/deepmerge/-/deepmerge-4.2.2.tgz#44d2ea3679b8f4d4ffba33f03d865fc1e7bf4955" - integrity sha512-FJ3UgI4gIl+PHZm53knsuSFpE+nESMr7M4v9QcgB7S63Kj/6WqMiFQJpBBYz1Pt+66bZpP3Q7Lye0Oo9MPKEdg== - default-compare@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/default-compare/-/default-compare-1.0.0.tgz#cb61131844ad84d84788fb68fd01681ca7781a2f" @@ -1534,6 +1201,11 @@ define-property@^2.0.2: is-descriptor "^1.0.2" isobject "^3.0.1" +detect-indent@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/detect-indent/-/detect-indent-6.0.0.tgz#0abd0f549f69fc6659a254fe96786186b6f528fd" + integrity sha512-oSyFlqaTHCItVRGK5RmrmjB+CmaMOW7IaNA/kdxqhoa6d17j/5ce9O9eWXmV/KEdRwqpQA+Vqe8a8Bsybu4YnA== + diff@^4.0.1: version "4.0.2" resolved "https://registry.yarnpkg.com/diff/-/diff-4.0.2.tgz#60f3aecb89d5fae520c11aa19efc2bb982aade7d" @@ -1614,11 +1286,6 @@ esprima@^4.0.0: resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.1.tgz#13b04cdb3e6c5d19df91ab6987a8695619b0aa71" integrity sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A== -estree-walker@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/estree-walker/-/estree-walker-1.0.1.tgz#31bc5d612c96b704106b477e6dd5d8aa138cb700" - integrity sha512-1fMXF3YP4pZZVozF8j/ZLfvnR8NSIljt56UhbZ5PeeDmmGHpgpdwQt7ITlGvYaQukCvuBRMLEiKiYC+oeIg4cg== - execa@^0.7.0: version "0.7.0" resolved "https://registry.yarnpkg.com/execa/-/execa-0.7.0.tgz#944becd34cc41ee32a63a9faf27ad5a65fc59777" @@ -1665,6 +1332,15 @@ extendable-error@^0.1.5: resolved "https://registry.yarnpkg.com/extendable-error/-/extendable-error-0.1.7.tgz#60b9adf206264ac920058a7395685ae4670c2b96" integrity sha512-UOiS2in6/Q0FK0R0q6UY9vYpQ21mr/Qn1KOnte7vsACuNJf514WvCCUHSRCPcgjPT2bAhNIJdlE6bVap1GKmeg== +external-editor@^3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/external-editor/-/external-editor-3.1.0.tgz#cb03f740befae03ea4d283caed2741a83f335495" + integrity sha512-hMQ4CX1p1izmuLYyZqLMO/qGNw10wSv9QDCPfzXfyFrOaCSSoRfqE1Kf1s5an66J5JZC62NewG+mK49jOCtQew== + dependencies: + chardet "^0.7.0" + iconv-lite "^0.4.24" + tmp "^0.0.33" + extglob@^2.0.4: version "2.0.4" resolved "https://registry.yarnpkg.com/extglob/-/extglob-2.0.4.tgz#ad00fe4dc612a9232e8718711dc5cb5ab0285543" @@ -1698,6 +1374,18 @@ fast-glob@^3.1.1: micromatch "^4.0.2" picomatch "^2.2.1" +fast-glob@^3.2.5: + version "3.2.5" + resolved "https://registry.yarnpkg.com/fast-glob/-/fast-glob-3.2.5.tgz#7939af2a656de79a4f1901903ee8adcaa7cb9661" + integrity sha512-2DtFcgT68wiTTiwZ2hNdJfcHNke9XOfnwmBRWXhmeKM8rF0TGwmC/Qto3S7RoZKp5cilZbxzO5iTNTQsJ+EeDg== + dependencies: + "@nodelib/fs.stat" "^2.0.2" + "@nodelib/fs.walk" "^1.2.3" + glob-parent "^5.1.0" + merge2 "^1.3.0" + micromatch "^4.0.2" + picomatch "^2.2.1" + fastq@^1.6.0: version "1.8.0" resolved "https://registry.yarnpkg.com/fastq/-/fastq-1.8.0.tgz#550e1f9f59bbc65fe185cb6a9b4d95357107f481" @@ -1722,13 +1410,6 @@ fill-range@^7.0.1: dependencies: to-regex-range "^5.0.1" -find-up@^2.0.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/find-up/-/find-up-2.1.0.tgz#45d1b7e506c717ddd482775a2b77920a3c0c57a7" - integrity sha1-RdG35QbHF93UgndaK3eSCjwMV6c= - dependencies: - locate-path "^2.0.0" - find-up@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/find-up/-/find-up-3.0.0.tgz#49169f1d7993430646da61ecc5ae355c21c97b73" @@ -1804,11 +1485,6 @@ fsevents@~2.1.2: resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-2.1.3.tgz#fb738703ae8d2f9fe900c33836ddebee8b97f23e" integrity sha512-Auw9a4AxqWpa9GUfj370BMPzzyncfBABW8Mab7BGWBYDj4Isgq+cDKtx0i6u9jcX9pQDnswsaaOTgTmA5pEjuQ== -gensync@^1.0.0-beta.1: - version "1.0.0-beta.1" - resolved "https://registry.yarnpkg.com/gensync/-/gensync-1.0.0-beta.1.tgz#58f4361ff987e5ff6e1e7a210827aa371eaac269" - integrity sha512-r8EC6NO1sngH/zdD9fiRDLdcgnbayXah+mLgManTaIZJqEC1MZstmnox8KpnI2/fxQwrp5OpCOYWLp4rBl4Jcg== - get-caller-file@^2.0.1: version "2.0.5" resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-2.0.5.tgz#4f94412a82db32f36e3b0b9741f8a97feb031f7e" @@ -1872,11 +1548,6 @@ global-dirs@^2.0.1: dependencies: ini "^1.3.5" -globals@^11.1.0: - version "11.12.0" - resolved "https://registry.yarnpkg.com/globals/-/globals-11.12.0.tgz#ab8795338868a0babd8525758018c2a7eb95c42e" - integrity sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA== - globby@^11.0.0: version "11.0.1" resolved "https://registry.yarnpkg.com/globby/-/globby-11.0.1.tgz#9a2bf107a068f3ffeabc49ad702c79ede8cfd357" @@ -1987,6 +1658,11 @@ handlebars@>=4.1.0, handlebars@^4.0.11, handlebars@^4.7.6: optionalDependencies: uglify-js "^3.1.4" +hard-rejection@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/hard-rejection/-/hard-rejection-2.1.0.tgz#1c6eda5c1685c63942766d79bb40ae773cecd883" + integrity sha512-VIZB+ibDhx7ObhAe7OVtoEbuP4h/MuOTHJ+J8h/eBXotJYl0fBgR72xDFCKgIh22OJZIOVNxBMWuhAr10r8HdA== + has-flag@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-3.0.0.tgz#b5d454dc2199ae225699f3467e5a07f3b955bafd" @@ -2089,6 +1765,13 @@ human-id@^1.0.2: resolved "https://registry.yarnpkg.com/human-id/-/human-id-1.0.2.tgz#e654d4b2b0d8b07e45da9f6020d8af17ec0a5df3" integrity sha512-UNopramDEhHJD+VR+ehk8rOslwSfByxPIZyJRfV739NDhN5LF1fa1MqnzKm2lGTQRjNrjK19Q5fhkgIfjlVUKw== +iconv-lite@^0.4.24: + version "0.4.24" + resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.24.tgz#2022b4b25fbddc21d2f524974a474aafe733908b" + integrity sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA== + dependencies: + safer-buffer ">= 2.1.2 < 3" + ignore-by-default@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/ignore-by-default/-/ignore-by-default-1.0.1.tgz#48ca6d72f6c6a3af00a9ad4ae6876be3889e2b09" @@ -2099,14 +1782,6 @@ ignore@^5.1.4: resolved "https://registry.yarnpkg.com/ignore/-/ignore-5.1.8.tgz#f150a8b50a34289b33e22f5889abd4d8016f0e57" integrity sha512-BMpfD7PpiETpBl/A6S498BaIJ6Y/ABT93ETbby2fP00v4EbvPBXWEoaR1UBPKs3iR53pJY7EtZk5KACI57i1Uw== -import-fresh@^3.1.0: - version "3.2.1" - resolved "https://registry.yarnpkg.com/import-fresh/-/import-fresh-3.2.1.tgz#633ff618506e793af5ac91bf48b72677e15cbe66" - integrity sha512-6e1q1cnWP2RXD9/keSkxHScg508CdXqXWgWBaETNhyuBFz+kUZlKboh+ISK+bU++DmbHimVBrOz/zzPe0sZ3sQ== - dependencies: - parent-module "^1.0.0" - resolve-from "^4.0.0" - import-lazy@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/import-lazy/-/import-lazy-2.1.0.tgz#05698e3d45c88e8d7e9d92cb0584e77f096f3e43" @@ -2117,10 +1792,10 @@ imurmurhash@^0.1.4: resolved "https://registry.yarnpkg.com/imurmurhash/-/imurmurhash-0.1.4.tgz#9218b9b2b928a238b13dc4fb6b6d576f231453ea" integrity sha1-khi5srkoojixPcT7a21XbyMUU+o= -indent-string@^3.0.0: - version "3.2.0" - resolved "https://registry.yarnpkg.com/indent-string/-/indent-string-3.2.0.tgz#4a5fd6d27cc332f37e5419a504dbb837105c9289" - integrity sha1-Sl/W0nzDMvN+VBmlBNu4NxBckok= +indent-string@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/indent-string/-/indent-string-4.0.0.tgz#624f8f4497d619b2d9768531d58f4122854d7251" + integrity sha512-EdDDZu4A2OyIK7Lr/2zG+w5jmbuk1DVBnEwREQvBzspBJkCEbRa8GxU1lghYcaGJCnRWibjDXlq779X1/y5xwg== inflight@^1.0.4: version "1.0.6" @@ -2145,6 +1820,14 @@ ini@^1.3.5, ini@~1.3.0: resolved "https://registry.yarnpkg.com/ini/-/ini-1.3.5.tgz#eee25f56db1c9ec6085e0c22778083f596abf927" integrity sha512-RZY5huIKCMRWDUqZlEi72f/lmXKMvuszcMBduliQ3nnWbx9X/ZBQO7DijMEYS9EhHBb2qacRUMtC7svLwe0lcw== +is-absolute@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/is-absolute/-/is-absolute-1.0.0.tgz#395e1ae84b11f26ad1795e73c17378e48a301576" + integrity sha512-dOWoqflvcydARa360Gvv18DZ/gRuHKi2NU/wU5X1ZFzdYfH29nkiNZsF3mp4OJ3H4yo9Mx8A/uAGNzpzPN3yBA== + dependencies: + is-relative "^1.0.0" + is-windows "^1.0.1" + is-accessor-descriptor@^0.1.6: version "0.1.6" resolved "https://registry.yarnpkg.com/is-accessor-descriptor/-/is-accessor-descriptor-0.1.6.tgz#a9e12cb3ae8d876727eeef3843f8a0897b5c98d6" @@ -2264,10 +1947,10 @@ is-installed-globally@^0.3.1: global-dirs "^2.0.1" is-path-inside "^3.0.1" -is-module@^1.0.0: +is-negated-glob@^1.0.0: version "1.0.0" - resolved "https://registry.yarnpkg.com/is-module/-/is-module-1.0.0.tgz#3258fb69f78c14d5b815d664336b4cffb6441591" - integrity sha1-Mlj7afeMFNW4FdZkM2tM/7ZEFZE= + resolved "https://registry.yarnpkg.com/is-negated-glob/-/is-negated-glob-1.0.0.tgz#6910bca5da8c95e784b5751b976cf5a10fee36d2" + integrity sha1-aRC8pdqMleeEtXUbl2z1oQ/uNtI= is-npm@^4.0.0: version "4.0.0" @@ -2327,6 +2010,13 @@ is-plain-object@^2.0.3, is-plain-object@^2.0.4: dependencies: isobject "^3.0.1" +is-relative@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/is-relative/-/is-relative-1.0.0.tgz#a1bb6935ce8c5dba1e8b9754b9b2dcc020e2260d" + integrity sha512-Kw/ReK0iqwKeu0MITLFuj0jbPAmEiOsIwyIXvvbfa6QfmN9pkD1M+8pdk7Rl/dTKbH34/XBFMbgD4iMJhLQbGA== + dependencies: + is-unc-path "^1.0.0" + is-self-closing@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/is-self-closing/-/is-self-closing-1.0.1.tgz#5f406b527c7b12610176320338af0fa3896416e4" @@ -2351,7 +2041,14 @@ is-typedarray@^1.0.0: resolved "https://registry.yarnpkg.com/is-typedarray/-/is-typedarray-1.0.0.tgz#e479c80858df0c1b11ddda6940f96011fcda4a9a" integrity sha1-5HnICFjfDBsR3dppQPlgEfzaSpo= -is-windows@^1.0.0, is-windows@^1.0.2: +is-unc-path@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/is-unc-path/-/is-unc-path-1.0.0.tgz#d731e8898ed090a12c352ad2eaed5095ad322c9d" + integrity sha512-mrGpVd0fs7WWLfVsStvgF6iEJnbjDFZh9/emhRDcGWTduTfNHd9CHeUwH3gYIjdbwo4On6hunkztwOaAw0yllQ== + dependencies: + unc-path-regex "^0.1.2" + +is-windows@^1.0.0, is-windows@^1.0.1, is-windows@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/is-windows/-/is-windows-1.0.2.tgz#d1850eb9791ecd18e6182ce12a30f396634bb19d" integrity sha512-eXK1UInq2bPmjyX6e3VHIzMLobc4J94i4AWn+Hpq3OU5KkrRC96OAcR3PRJ/pGu6m8TRnBHP9dkXQVsT/COVIA== @@ -2401,27 +2098,15 @@ js-yaml@^3.13.0, js-yaml@^3.13.1, js-yaml@^3.6.1: argparse "^1.0.7" esprima "^4.0.0" -jsesc@^2.5.1: - version "2.5.2" - resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-2.5.2.tgz#80564d2e483dacf6e8ef209650a67df3f0c283a4" - integrity sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA== - json-buffer@3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/json-buffer/-/json-buffer-3.0.0.tgz#5b1f397afc75d677bde8bcfc0e47e1f9a3d9a898" integrity sha1-Wx85evx11ne96Lz8Dkfh+aPZqJg= -json-parse-better-errors@^1.0.1: - version "1.0.2" - resolved "https://registry.yarnpkg.com/json-parse-better-errors/-/json-parse-better-errors-1.0.2.tgz#bb867cfb3450e69107c131d1c514bab3dc8bcaa9" - integrity sha512-mrqyZKfX5EhL7hvqcV6WG1yYjnjeuYDzDhhcAAUrq8Po85NBQBJP+ZDUT75qZQ98IkUoBqdkExkukOU7Ts2wrw== - -json5@^2.1.2: - version "2.1.3" - resolved "https://registry.yarnpkg.com/json5/-/json5-2.1.3.tgz#c9b0f7fa9233bfe5807fe66fcf3a5617ed597d43" - integrity sha512-KXPvOm8K9IJKFM0bmdn8QXh7udDh1g/giieX0NLCaMnb4hEiVFqnop2ImTXCc5e0/oHz3LTqmHGtExn5hfMkOA== - dependencies: - minimist "^1.2.5" +json-parse-even-better-errors@^2.3.0: + version "2.3.1" + resolved "https://registry.yarnpkg.com/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.1.tgz#7c47805a94319928e05777405dc12e1f7a4ee02d" + integrity sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w== jsonfile@^4.0.0: version "4.0.0" @@ -2456,7 +2141,7 @@ kind-of@^5.0.0, kind-of@^5.0.2: resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-5.1.0.tgz#729c91e2d857b7a419a1f9aa65685c4c33f5845d" integrity sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw== -kind-of@^6.0.0, kind-of@^6.0.2: +kind-of@^6.0.0, kind-of@^6.0.2, kind-of@^6.0.3: version "6.0.3" resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-6.0.3.tgz#07c05034a6c349fa06e24fa35aa76db4580ce4dd" integrity sha512-dcS1ul+9tmeD95T+x28/ehLgd9mENa3LsvDTtzm3vyBEO7RPptvAD+t44WVXaUjTBRcrpFeFlC8WCruUR456hw== @@ -2480,16 +2165,6 @@ lines-and-columns@^1.1.6: resolved "https://registry.yarnpkg.com/lines-and-columns/-/lines-and-columns-1.1.6.tgz#1c00c743b433cd0a4e80758f7b64a57440d9ff00" integrity sha1-HADHQ7QzzQpOgHWPe2SldEDZ/wA= -load-json-file@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/load-json-file/-/load-json-file-4.0.0.tgz#2f5f45ab91e33216234fd53adab668eb4ec0993b" - integrity sha1-L19Fq5HjMhYjT9U62rZo607AmTs= - dependencies: - graceful-fs "^4.1.2" - parse-json "^4.0.0" - pify "^3.0.0" - strip-bom "^3.0.0" - load-yaml-file@^0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/load-yaml-file/-/load-yaml-file-0.2.0.tgz#af854edaf2bea89346c07549122753c07372f64d" @@ -2500,14 +2175,6 @@ load-yaml-file@^0.2.0: pify "^4.0.1" strip-bom "^3.0.0" -locate-path@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/locate-path/-/locate-path-2.0.0.tgz#2b568b265eec944c6d9c0de9c3dbbbca0354cd8e" - integrity sha1-K1aLJl7slExtnA3pw9u7ygNUzY4= - dependencies: - p-locate "^2.0.0" - path-exists "^3.0.0" - locate-path@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/locate-path/-/locate-path-3.0.0.tgz#dbec3b3ab759758071b58fe59fc41871af21400e" @@ -2548,16 +2215,6 @@ lodash.templatesettings@^4.0.0: dependencies: lodash._reinterpolate "^3.0.0" -lodash@^4.17.13: - version "4.17.15" - resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.15.tgz#b447f6670a0455bbfeedd11392eff330ea097548" - integrity sha512-8xOcRHvCjnocdS5cpwXQXVzmmh5e5+saE2QGoeQmbKmRS6J3VQppPOIt0MnmE+4xlZoumy0GPG0D0MVIQbNA1A== - -lodash@^4.17.19: - version "4.17.20" - resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.20.tgz#b44a9b6297bcb698f1c51a3545a2b3b368d59c52" - integrity sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA== - log-ok@^0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/log-ok/-/log-ok-0.1.1.tgz#bea3dd36acd0b8a7240d78736b5b97c65444a334" @@ -2587,14 +2244,6 @@ logging-helpers@^1.0.0: isobject "^3.0.0" log-utils "^0.2.1" -loud-rejection@^1.0.0: - version "1.6.0" - resolved "https://registry.yarnpkg.com/loud-rejection/-/loud-rejection-1.6.0.tgz#5b46f80147edee578870f086d04821cf998e551f" - integrity sha1-W0b4AUft7leIcPCG0Eghz5mOVR8= - dependencies: - currently-unhandled "^0.4.1" - signal-exit "^3.0.0" - lowercase-keys@^1.0.0, lowercase-keys@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/lowercase-keys/-/lowercase-keys-1.0.1.tgz#6f9e30b47084d971a7c820ff15a6c5167b74c26f" @@ -2635,10 +2284,10 @@ map-obj@^1.0.0: resolved "https://registry.yarnpkg.com/map-obj/-/map-obj-1.0.1.tgz#d933ceb9205d82bdcf4886f6742bdc2b4dea146d" integrity sha1-2TPOuSBdgr3PSIb2dCvcK03qFG0= -map-obj@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/map-obj/-/map-obj-2.0.0.tgz#a65cd29087a92598b8791257a523e021222ac1f9" - integrity sha1-plzSkIepJZi4eRJXpSPgISIqwfk= +map-obj@^4.0.0: + version "4.2.1" + resolved "https://registry.yarnpkg.com/map-obj/-/map-obj-4.2.1.tgz#e4ea399dbc979ae735c83c863dd31bdf364277b7" + integrity sha512-+WA2/1sPmDj1dlvvJmB5G6JKfY9dpn7EVBUL06+y6PoljPkh+6V1QihwxNkbcGxCRjt2b0F9K0taiCuo7MbdFQ== map-visit@^1.0.0: version "1.0.0" @@ -2647,20 +2296,22 @@ map-visit@^1.0.0: dependencies: object-visit "^1.0.0" -meow@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/meow/-/meow-5.0.0.tgz#dfc73d63a9afc714a5e371760eb5c88b91078aa4" - integrity sha512-CbTqYU17ABaLefO8vCU153ZZlprKYWDljcndKKDCFcYQITzWCXZAVk4QMFZPgvzrnUQ3uItnIE/LoUOwrT15Ig== - dependencies: - camelcase-keys "^4.0.0" - decamelize-keys "^1.0.0" - loud-rejection "^1.0.0" - minimist-options "^3.0.1" - normalize-package-data "^2.3.4" - read-pkg-up "^3.0.0" - redent "^2.0.0" - trim-newlines "^2.0.0" - yargs-parser "^10.0.0" +meow@^6.0.0: + version "6.1.1" + resolved "https://registry.yarnpkg.com/meow/-/meow-6.1.1.tgz#1ad64c4b76b2a24dfb2f635fddcadf320d251467" + integrity sha512-3YffViIt2QWgTy6Pale5QpopX/IvU3LPL03jOTqp6pGj3VjesdO/U8CuHMKpnQr4shCNCM5fd5XFFvIIl6JBHg== + dependencies: + "@types/minimist" "^1.2.0" + camelcase-keys "^6.2.2" + decamelize-keys "^1.1.0" + hard-rejection "^2.1.0" + minimist-options "^4.0.2" + normalize-package-data "^2.5.0" + read-pkg-up "^7.0.1" + redent "^3.0.0" + trim-newlines "^3.0.0" + type-fest "^0.13.1" + yargs-parser "^18.1.3" merge2@^1.3.0: version "1.4.1" @@ -2699,6 +2350,11 @@ mimic-response@^1.0.0, mimic-response@^1.0.1: resolved "https://registry.yarnpkg.com/mimic-response/-/mimic-response-1.0.1.tgz#4923538878eef42063cb8a3e3b0798781487ab1b" integrity sha512-j5EctnkH7amfV/q5Hgmoal1g2QHFJRraOtmx0JpIqkxhBhI/lJSl1nMpQ45hVarwNETOoWEimndZ4QK0RHxuxQ== +min-indent@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/min-indent/-/min-indent-1.0.1.tgz#a63f681673b30571fbe8bc25686ae746eefa9869" + integrity sha512-I9jwMn07Sy/IwOj3zVkVik2JTvgpaykDZEigL6Rx6N9LbMywwUSMtxET+7lVoDLLd3O3IXwJwvuuns8UB/HeAg== + minimatch@^3.0.4: version "3.0.4" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.4.tgz#5166e286457f03306064be5497e8dbb0c3d32083" @@ -2706,13 +2362,14 @@ minimatch@^3.0.4: dependencies: brace-expansion "^1.1.7" -minimist-options@^3.0.1: - version "3.0.2" - resolved "https://registry.yarnpkg.com/minimist-options/-/minimist-options-3.0.2.tgz#fba4c8191339e13ecf4d61beb03f070103f3d954" - integrity sha512-FyBrT/d0d4+uiZRbqznPXqw3IpZZG3gl3wKWiX784FycUKVwBt0uLBFkQrtE4tZOrgo78nZp2jnKz3L65T5LdQ== +minimist-options@^4.0.2: + version "4.1.0" + resolved "https://registry.yarnpkg.com/minimist-options/-/minimist-options-4.1.0.tgz#c0655713c53a8a2ebd77ffa247d342c40f010619" + integrity sha512-Q4r8ghd80yhO/0j1O3B2BjweX3fiHg9cdOwjJd2J76Q135c+NDxGCqdYKQ1SKBuFfgWbAUzBfvYjPUEeNgqN1A== dependencies: arrify "^1.0.1" is-plain-obj "^1.1.0" + kind-of "^6.0.3" minimist@^1.2.0, minimist@^1.2.5: version "1.2.5" @@ -2732,6 +2389,11 @@ mixme@^0.3.1: resolved "https://registry.yarnpkg.com/mixme/-/mixme-0.3.5.tgz#304652cdaf24a3df0487205e61ac6162c6906ddd" integrity sha512-SyV9uPETRig5ZmYev0ANfiGeB+g6N2EnqqEfBbCGmmJ6MgZ3E4qv5aPbnHVdZ60KAHHXV+T3sXopdrnIXQdmjQ== +mkdirp@^1.0.4: + version "1.0.4" + resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-1.0.4.tgz#3eb5ed62622756d79a5f0e2a221dfebad75c2f7e" + integrity sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw== + moment@^2.18.1: version "2.27.0" resolved "https://registry.yarnpkg.com/moment/-/moment-2.27.0.tgz#8bff4e3e26a236220dfe3e36de756b6ebaa0105d" @@ -2747,6 +2409,17 @@ ms@^2.1.1: resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.2.tgz#d09d1f357b443f493382a8eb3ccd183872ae6009" integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== +multimatch@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/multimatch/-/multimatch-5.0.0.tgz#932b800963cea7a31a033328fa1e0c3a1874dbe6" + integrity sha512-ypMKuglUrZUD99Tk2bUQ+xNQj43lPEfAeX2o9cTteAmShXy2VHDJpuwu1o0xqoKCt9jLVAvwyFKdLTPXKAfJyA== + dependencies: + "@types/minimatch" "^3.0.3" + array-differ "^3.0.0" + array-union "^2.1.0" + arrify "^2.0.1" + minimatch "^3.0.4" + nanomatch@^1.2.9: version "1.2.13" resolved "https://registry.yarnpkg.com/nanomatch/-/nanomatch-1.2.13.tgz#b87a8aa4fc0de8fe6be88895b38983ff265bd119" @@ -2792,7 +2465,7 @@ nopt@~1.0.10: dependencies: abbrev "1" -normalize-package-data@^2.3.2, normalize-package-data@^2.3.4: +normalize-package-data@^2.5.0: version "2.5.0" resolved "https://registry.yarnpkg.com/normalize-package-data/-/normalize-package-data-2.5.0.tgz#e66db1838b200c1dfc233225d12cb36520e234a8" integrity sha512-/5CMN3T0R4XTj4DcGaexo+roZSdSFW/0AOOTROrjxzCG1wrWXEsGbRKevjlIL+ZDE4sZlJr5ED4YW0yqmkK+eA== @@ -2849,6 +2522,11 @@ once@^1.3.0, once@^1.3.1, once@^1.4.0: dependencies: wrappy "1" +os-tmpdir@~1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/os-tmpdir/-/os-tmpdir-1.0.2.tgz#bbe67406c79aa85c5cfec766fe5734555dfa1274" + integrity sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ= + outdent@^0.5.0: version "0.5.0" resolved "https://registry.yarnpkg.com/outdent/-/outdent-0.5.0.tgz#9e10982fdc41492bb473ad13840d22f9655be2ff" @@ -2871,13 +2549,6 @@ p-finally@^1.0.0: resolved "https://registry.yarnpkg.com/p-finally/-/p-finally-1.0.0.tgz#3fbcfb15b899a44123b34b6dcc18b724336a2cae" integrity sha1-P7z7FbiZpEEjs0ttzBi3JDNqLK4= -p-limit@^1.1.0: - version "1.3.0" - resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-1.3.0.tgz#b86bd5f0c25690911c7590fcbfc2010d54b3ccb8" - integrity sha512-vvcXsLAJ9Dr5rQOPk7toZQZJApBl2K4J6dANSsEuh6QI41JYcsS/qhTGa9ErIUUgK3WNQoJYvylxvjqmiqEA9Q== - dependencies: - p-try "^1.0.0" - p-limit@^2.0.0, p-limit@^2.2.0: version "2.3.0" resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-2.3.0.tgz#3dd33c647a214fdfffd835933eb086da0dc21db1" @@ -2885,13 +2556,6 @@ p-limit@^2.0.0, p-limit@^2.2.0: dependencies: p-try "^2.0.0" -p-locate@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/p-locate/-/p-locate-2.0.0.tgz#20a0103b222a70c8fd39cc2e580680f3dde5ec43" - integrity sha1-IKAQOyIqcMj9OcwuWAaA893l7EM= - dependencies: - p-limit "^1.1.0" - p-locate@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/p-locate/-/p-locate-3.0.0.tgz#322d69a05c0264b25997d9f40cd8a891ab0064a4" @@ -2911,11 +2575,6 @@ p-map@^2.0.0: resolved "https://registry.yarnpkg.com/p-map/-/p-map-2.1.0.tgz#310928feef9c9ecc65b68b17693018a665cea175" integrity sha512-y3b8Kpd8OAN444hxfBbFfj1FY/RjtTd8tzYwhUqNYXx0fXx2iX4maP4Qr6qhIKbQXI02wTLAda4fYUbDagTUFw== -p-try@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/p-try/-/p-try-1.0.0.tgz#cbc79cdbaf8fd4228e13f621f2b1a237c1b207b3" - integrity sha1-y8ec26+P1CKOE/Yh8rGiN8GyB7M= - p-try@^2.0.0: version "2.2.0" resolved "https://registry.yarnpkg.com/p-try/-/p-try-2.2.0.tgz#cb2868540e313d61de58fafbe35ce9004d5540e6" @@ -2931,29 +2590,14 @@ package-json@^6.3.0: registry-url "^5.0.0" semver "^6.2.0" -parent-module@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/parent-module/-/parent-module-1.0.1.tgz#691d2709e78c79fae3a156622452d00762caaaa2" - integrity sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g== - dependencies: - callsites "^3.0.0" - -parse-json@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-4.0.0.tgz#be35f5425be1f7f6c747184f98a788cb99477ee0" - integrity sha1-vjX1Qlvh9/bHRxhPmKeIy5lHfuA= - dependencies: - error-ex "^1.3.1" - json-parse-better-errors "^1.0.1" - parse-json@^5.0.0: - version "5.0.1" - resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-5.0.1.tgz#7cfe35c1ccd641bce3981467e6c2ece61b3b3878" - integrity sha512-ztoZ4/DYeXQq4E21v169sC8qWINGpcosGv9XhTDvg9/hWvx/zrFkc9BiWxR58OJLHGk28j5BL0SDLeV2WmFZlQ== + version "5.2.0" + resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-5.2.0.tgz#c76fc66dee54231c962b22bcc8a72cf2f99753cd" + integrity sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg== dependencies: "@babel/code-frame" "^7.0.0" error-ex "^1.3.1" - json-parse-better-errors "^1.0.1" + json-parse-even-better-errors "^2.3.0" lines-and-columns "^1.1.6" pascalcase@^0.1.1: @@ -2986,28 +2630,16 @@ path-parse@^1.0.6: resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.6.tgz#d62dbb5679405d72c4737ec58600e9ddcf06d24c" integrity sha512-GSmOT2EbHrINBf9SR7CDELwlJ8AENk3Qn7OikK4nFYAu3Ote2+JYNVvkpAEQm3/TLNEJFD/xZJjzyxg3KBWOzw== -path-type@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/path-type/-/path-type-3.0.0.tgz#cef31dc8e0a1a3bb0d105c0cd97cf3bf47f4e36f" - integrity sha512-T2ZUsdZFHgA3u4e5PfPbjd7HDDpxPnQb5jN0SrDsjNSuVXHJqtwTnWqG0B1jZrgmJ/7lj1EmVIByWt1gxGkWvg== - dependencies: - pify "^3.0.0" - path-type@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/path-type/-/path-type-4.0.0.tgz#84ed01c0a7ba380afe09d90a8c180dcd9d03043b" integrity sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw== -picomatch@^2.0.4, picomatch@^2.0.5, picomatch@^2.2.1, picomatch@^2.2.2: +picomatch@^2.0.4, picomatch@^2.0.5, picomatch@^2.2.1: version "2.2.2" resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.2.2.tgz#21f333e9b6b8eaff02468f5146ea406d345f4dad" integrity sha512-q0M/9eZHzmr0AulXyPwNfZjtwZ/RBZlbN3K3CErVrk50T2ASYI7Bye0EvekFY3IP1Nt2DHu0re+V2ZHIpMkuWg== -pify@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/pify/-/pify-3.0.0.tgz#e5a4acd2c101fdf3d9a4d07f0dbc4db49dd28176" - integrity sha1-5aSs0sEB/fPZpNB/DbxNtJ3SgXY= - pify@^4.0.1: version "4.0.1" resolved "https://registry.yarnpkg.com/pify/-/pify-4.0.1.tgz#4b2cd25c50d598735c50292224fd8c6df41e3231" @@ -3047,7 +2679,7 @@ prepend-http@^2.0.0: resolved "https://registry.yarnpkg.com/prepend-http/-/prepend-http-2.0.0.tgz#e92434bfa5ea8c19f41cdfd401d741a3c819d897" integrity sha1-6SQ0v6XqjBn0HN/UAddBo8gZ2Jc= -prettier@^1.18.2: +prettier@^1.19.1: version "1.19.1" resolved "https://registry.yarnpkg.com/prettier/-/prettier-1.19.1.tgz#f7d7f5ff8a9cd872a7be4ca142095956a60797cb" integrity sha512-s7PoyDv/II1ObgQunCbB9PdLmUcBZcnWOcxDh7O0N/UwDEsHyqkW+Qh28jW+mVuCdx7gLB0BotYI1Y6uI9iyew== @@ -3082,10 +2714,10 @@ pupa@^2.0.1: dependencies: escape-goat "^2.0.0" -quick-lru@^1.0.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/quick-lru/-/quick-lru-1.1.0.tgz#4360b17c61136ad38078397ff11416e186dcfbb8" - integrity sha1-Q2CxfGETatOAeDl/8RQW4Ybc+7g= +quick-lru@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/quick-lru/-/quick-lru-4.0.1.tgz#5b8878f113a58217848c6482026c73e1ba57727f" + integrity sha512-ARhCpm70fzdcvNQfPoy49IaanKkTlRWF2JMzqhcJbhSFRZv7nPTvZJdcY7301IPmvW+/p0RgIWnQDLJxifsQ7g== rc@^1.2.8: version "1.2.8" @@ -3097,22 +2729,24 @@ rc@^1.2.8: minimist "^1.2.0" strip-json-comments "~2.0.1" -read-pkg-up@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/read-pkg-up/-/read-pkg-up-3.0.0.tgz#3ed496685dba0f8fe118d0691dc51f4a1ff96f07" - integrity sha1-PtSWaF26D4/hGNBpHcUfSh/5bwc= +read-pkg-up@^7.0.1: + version "7.0.1" + resolved "https://registry.yarnpkg.com/read-pkg-up/-/read-pkg-up-7.0.1.tgz#f3a6135758459733ae2b95638056e1854e7ef507" + integrity sha512-zK0TB7Xd6JpCLmlLmufqykGE+/TlOePD6qKClNW7hHDKFh/J7/7gCWGR7joEQEW1bKq3a3yUZSObOoWLFQ4ohg== dependencies: - find-up "^2.0.0" - read-pkg "^3.0.0" + find-up "^4.1.0" + read-pkg "^5.2.0" + type-fest "^0.8.1" -read-pkg@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/read-pkg/-/read-pkg-3.0.0.tgz#9cbc686978fee65d16c00e2b19c237fcf6e38389" - integrity sha1-nLxoaXj+5l0WwA4rGcI3/Pbjg4k= +read-pkg@^5.2.0: + version "5.2.0" + resolved "https://registry.yarnpkg.com/read-pkg/-/read-pkg-5.2.0.tgz#7bf295438ca5a33e56cd30e053b34ee7250c93cc" + integrity sha512-Ug69mNOpfvKDAc2Q8DRpMjjzdtrnv9HcSMX+4VsZxD1aZ6ZzrIE7rlzXBtWTyhULSMKg076AW6WR5iZpD0JiOg== dependencies: - load-json-file "^4.0.0" - normalize-package-data "^2.3.2" - path-type "^3.0.0" + "@types/normalize-package-data" "^2.4.0" + normalize-package-data "^2.5.0" + parse-json "^5.0.0" + type-fest "^0.6.0" read-yaml-file@^1.1.0: version "1.1.0" @@ -3151,13 +2785,13 @@ readdirp@~3.5.0: dependencies: picomatch "^2.2.1" -redent@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/redent/-/redent-2.0.0.tgz#c1b2007b42d57eb1389079b3c8333639d5e1ccaa" - integrity sha1-wbIAe0LVfrE4kHmzyDM2OdXhzKo= +redent@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/redent/-/redent-3.0.0.tgz#e557b7998316bb53c9f1f56fa626352c6963059f" + integrity sha512-6tDA8g98We0zd0GvVeMT9arEOnTw9qM03L9cJXaCjrip1OO764RDBLBfrB4cwzNGDj5OA5ioymC9GkizgWJDUg== dependencies: - indent-string "^3.0.0" - strip-indent "^2.0.0" + indent-string "^4.0.0" + strip-indent "^3.0.0" regenerator-runtime@^0.13.4: version "0.13.7" @@ -3221,11 +2855,6 @@ require-main-filename@^2.0.0: resolved "https://registry.yarnpkg.com/require-main-filename/-/require-main-filename-2.0.0.tgz#d0b329ecc7cc0f61649f62215be69af54aa8989b" integrity sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg== -resolve-from@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-4.0.0.tgz#4abcd852ad32dd7baabfe9b40e00a36db5f392e6" - integrity sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g== - resolve-from@^5.0.0: version "5.0.0" resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-5.0.0.tgz#c35225843df8f776df21c57557bc087e9dfdfc69" @@ -3236,7 +2865,7 @@ resolve-url@^0.2.1: resolved "https://registry.yarnpkg.com/resolve-url/-/resolve-url-0.2.1.tgz#2c637fe77c893afd2a663fe21aa9080068e2052a" integrity sha1-LGN/53yJOv0qZj/iGqkIAGjiBSo= -resolve@^1.10.0, resolve@^1.12.0, resolve@^1.17.0, resolve@^1.3.2: +resolve@^1.10.0: version "1.17.0" resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.17.0.tgz#b25941b54968231cc2d1bb76a79cb7f2c0bf8444" integrity sha512-ic+7JYiV8Vi2yzQGFWOkiZD5Z9z7O2Zhm9XMaTxdJExKasieFCr+yXZ/WmXsckHiKl12ar0y6XiXDx3m4RHn1w== @@ -3267,13 +2896,6 @@ rimraf@^3.0.2: dependencies: glob "^7.1.3" -rollup@^2.26.3: - version "2.26.3" - resolved "https://registry.yarnpkg.com/rollup/-/rollup-2.26.3.tgz#502c755872a4590937cfa4e8f7eb99d3bc3c4025" - integrity sha512-Mlt39/kL2rA9egcbQbaZV1SNVplGqYYhDDMcGgHPPE0tvM3R4GrB+IEdYy2QtTrdzMQx57ZcqDFf/KWWm8F+uw== - optionalDependencies: - fsevents "~2.1.2" - run-parallel@^1.1.9: version "1.1.9" resolved "https://registry.yarnpkg.com/run-parallel/-/run-parallel-1.1.9.tgz#c9dd3a7cf9f4b2c4b6244e173a6ed866e61dd679" @@ -3291,6 +2913,11 @@ safe-regex@^1.1.0: dependencies: ret "~0.1.10" +"safer-buffer@>= 2.1.2 < 3": + version "2.1.2" + resolved "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a" + integrity sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg== + self-closing-tags@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/self-closing-tags/-/self-closing-tags-1.0.1.tgz#6c5fa497994bb826b484216916371accee490a5d" @@ -3422,7 +3049,7 @@ source-map-url@^0.4.0: resolved "https://registry.yarnpkg.com/source-map-url/-/source-map-url-0.4.0.tgz#3e935d7ddd73631b97659956d55128e87b5084a3" integrity sha1-PpNdfd1zYxuXZZlW1VEo6HtQhKM= -source-map@^0.5.0, source-map@^0.5.6: +source-map@^0.5.6: version "0.5.7" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.5.7.tgz#8a039d2d1021d22d1ea14c80d8ea468ba2ef3fcc" integrity sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w= @@ -3557,10 +3184,12 @@ strip-eof@^1.0.0: resolved "https://registry.yarnpkg.com/strip-eof/-/strip-eof-1.0.0.tgz#bb43ff5598a6eb05d89b59fcd129c983313606bf" integrity sha1-u0P/VZim6wXYm1n80SnJgzE2Br8= -strip-indent@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/strip-indent/-/strip-indent-2.0.0.tgz#5ef8db295d01e6ed6cbf7aab96998d7822527b68" - integrity sha1-XvjbKV0B5u1sv3qrlpmNeCJSe2g= +strip-indent@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/strip-indent/-/strip-indent-3.0.0.tgz#c32e1cee940b6b3432c771bc2c54bcce73cd3001" + integrity sha512-laJTa3Jb+VQpaC6DseHhF7dXVqHTfJPCRDaEbid/drOhgitgYku/letMUqOXFoWV0zIIUbjpdH2t+tYj4bQMRQ== + dependencies: + min-indent "^1.0.0" strip-json-comments@~2.0.1: version "2.0.1" @@ -3616,10 +3245,12 @@ time-stamp@^1.0.1: resolved "https://registry.yarnpkg.com/time-stamp/-/time-stamp-1.1.0.tgz#764a5a11af50561921b133f3b44e618687e0f5c3" integrity sha1-dkpaEa9QVhkhsTPztE5hhofg9cM= -to-fast-properties@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/to-fast-properties/-/to-fast-properties-2.0.0.tgz#dc5e698cbd079265bc73e0377681a4e4e83f616e" - integrity sha1-3F5pjL0HkmW8c+A3doGk5Og/YW4= +tmp@^0.0.33: + version "0.0.33" + resolved "https://registry.yarnpkg.com/tmp/-/tmp-0.0.33.tgz#6d34335889768d21b2bcda0aa277ced3b1bfadf9" + integrity sha512-jRCJlojKnZ3addtTOjdIqoRuPEKBvNXcGYqzO6zWZX8KfKEpnGY5jfggJQ3EjKuu8D4bJRr0y+cYJFmYbImXGw== + dependencies: + os-tmpdir "~1.0.2" to-gfm-code-block@^0.1.1: version "0.1.1" @@ -3670,12 +3301,21 @@ touch@^3.1.0: dependencies: nopt "~1.0.10" -trim-newlines@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/trim-newlines/-/trim-newlines-2.0.0.tgz#b403d0b91be50c331dfc4b82eeceb22c3de16d20" - integrity sha1-tAPQuRvlDDMd/EuC7s6yLD3hbSA= +trim-newlines@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/trim-newlines/-/trim-newlines-3.0.0.tgz#79726304a6a898aa8373427298d54c2ee8b1cb30" + integrity sha512-C4+gOpvmxaSMKuEf9Qc134F1ZuOHVXKRbtEflf4NTtuuJDEIJ9p5PXsalL8SkeRw+qit1Mo+yuvMPAKwWg/1hA== -ts-node@9.0.0: +ts-morph@^10.0.1: + version "10.0.1" + resolved "https://registry.yarnpkg.com/ts-morph/-/ts-morph-10.0.1.tgz#5a620cc4ef85e3e6d161989e690f44d0a0f723b0" + integrity sha512-T1zufImtp5goTLTFhzi7XuKR1y/f+Jwz1gSULzB045LFjXuoqVlR87sfkpyWow8u2JwgusCJrhOnwmHCFNutTQ== + dependencies: + "@dsherret/to-absolute-glob" "^2.0.2" + "@ts-morph/common" "~0.8.0" + code-block-writer "^10.1.1" + +ts-node@9.0.0, ts-node@^9.0.0: version "9.0.0" resolved "https://registry.yarnpkg.com/ts-node/-/ts-node-9.0.0.tgz#e7699d2a110cc8c0d3b831715e417688683460b3" integrity sha512-/TqB4SnererCDR/vb4S/QvSZvzQMJN8daAslg7MeaiHvD8rDZsSfXmNeNumyZZzMned72Xoq/isQljYSt8Ynfg== @@ -3686,7 +3326,7 @@ ts-node@9.0.0: source-map-support "^0.5.17" yn "3.1.1" -tty-table@^2.7.0: +tty-table@^2.8.10: version "2.8.13" resolved "https://registry.yarnpkg.com/tty-table/-/tty-table-2.8.13.tgz#d484a416381973eaebbdf19c79136b390e5c6d70" integrity sha512-eVV/+kB6fIIdx+iUImhXrO22gl7f6VmmYh0Zbu6C196fe1elcHXd7U6LcLXu0YoVPc2kNesWiukYcdK8ZmJ6aQ== @@ -3698,6 +3338,16 @@ tty-table@^2.7.0: wcwidth "^1.0.1" yargs "^15.1.0" +type-fest@^0.13.1: + version "0.13.1" + resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-0.13.1.tgz#0172cb5bce80b0bd542ea348db50c7e21834d934" + integrity sha512-34R7HTnG0XIJcBSn5XhDd7nNFPRcXYRZrBB2O2jdKqYODldSzBAqzsWoZYYvduky73toYS/ESqxPvkDf/F0XMg== + +type-fest@^0.6.0: + version "0.6.0" + resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-0.6.0.tgz#8d2a2370d3df886eb5c90ada1c5bf6188acf838b" + integrity sha512-q+MB8nYR1KDLrgr4G5yemftpMC7/QLqVndBmEEdqzmNj5dcFOO4Oo8qlwZE3ULT3+Zim1F8Kq4cBnikNhlCMlg== + type-fest@^0.8.1: version "0.8.1" resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-0.8.1.tgz#09e249ebde851d3b1e48d27c105444667f17b83d" @@ -3727,6 +3377,11 @@ uglify-js@^3.1.4: resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-3.10.0.tgz#397a7e6e31ce820bfd1cb55b804ee140c587a9e7" integrity sha512-Esj5HG5WAyrLIdYU74Z3JdG2PxdIusvj6IWHMtlyESxc7kcDz7zYlYjpnSokn1UbpV0d/QX9fan7gkCNd/9BQA== +unc-path-regex@^0.1.2: + version "0.1.2" + resolved "https://registry.yarnpkg.com/unc-path-regex/-/unc-path-regex-0.1.2.tgz#e73dd3d7b0d7c5ed86fbac6b0ae7d8c6a69d50fa" + integrity sha1-5z3T17DXxe2G+6xrCufYxqadUPo= + undefsafe@^2.0.2: version "2.0.3" resolved "https://registry.yarnpkg.com/undefsafe/-/undefsafe-2.0.3.tgz#6b166e7094ad46313b2202da7ecc2cd7cc6e7aae" @@ -3913,19 +3568,7 @@ yallist@^2.1.2: resolved "https://registry.yarnpkg.com/yallist/-/yallist-2.1.2.tgz#1c11f9218f076089a47dd512f93c6699a6a81d52" integrity sha1-HBH5IY8HYImkfdUS+TxmmaaoHVI= -yaml@^1.7.2: - version "1.10.0" - resolved "https://registry.yarnpkg.com/yaml/-/yaml-1.10.0.tgz#3b593add944876077d4d683fee01081bd9fff31e" - integrity sha512-yr2icI4glYaNG+KWONODapy2/jDdMSDnrONSjblABjD9B4Z5LgiircSt8m8sRZFNi08kG9Sm0uSHtEmP3zaEGg== - -yargs-parser@^10.0.0: - version "10.1.0" - resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-10.1.0.tgz#7202265b89f7e9e9f2e5765e0fe735a905edbaa8" - integrity sha512-VCIyR1wJoEBZUqk5PA+oOBF6ypbwh5aNB3I50guxAL/quggdfs4TtNHQrSazFA3fYZ+tEqfs0zIGlv0c/rgjbQ== - dependencies: - camelcase "^4.1.0" - -yargs-parser@^18.1.2: +yargs-parser@^18.1.2, yargs-parser@^18.1.3: version "18.1.3" resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-18.1.3.tgz#be68c4975c6b2abf469236b0c870362fab09a7b0" integrity sha512-o50j0JeToy/4K6OZcaQmW6lyXXKhq7csREXcDwk2omFPJEwUNOVtJKvmDr9EI1fAJZUyZcRF7kxGBWmRXudrCQ==