Skip to content

Commit 9b796c8

Browse files
committed
remove category
1 parent ab820f0 commit 9b796c8

File tree

4 files changed

+3
-10
lines changed

4 files changed

+3
-10
lines changed

cli/types/cypress.d.ts

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3430,12 +3430,6 @@ declare namespace Cypress {
34303430
* @example `cypress-ct-${string} for third parties. Any string is valid internally.
34313431
*/
34323432
type: string
3433-
3434-
/**
3435-
* Only `library` is supported for third party definitions.
3436-
* `template` will be supported in the future.
3437-
*/
3438-
category: 'library'
34393433
}
34403434

34413435
interface AngularDevServerProjectConfig {

cli/types/tests/cypress-npm-api-test.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,6 @@ const solid = {
6767
const thirdPartyFrameworkDefinition = defineComponentFramework({
6868
type: 'cypress-ct-third-party',
6969
name: 'Third Party',
70-
category: 'library',
7170
dependencies: (bundler) => [solid],
7271
detectors: [solid],
7372
supportedBundlers: ['vite', 'webpack']
@@ -76,7 +75,6 @@ const thirdPartyFrameworkDefinition = defineComponentFramework({
7675
const thirdPartyFrameworkDefinitionInvalidStrings = defineComponentFramework({
7776
type: 'cypress-ct-third-party',
7877
name: 'Third Party',
79-
category: 'template', // $ExpectError
8078
dependencies: (bundler) => [],
8179
detectors: [{}], // $ExpectError
8280
supportedBundlers: ['metro', 'webpack'] // $ExpectError

packages/scaffold-config/src/ct-detect-third-party.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ const thirdPartyDefinitionPrefixes = {
2525
globalPrefix: 'cypress-ct-',
2626
}
2727

28-
export function isThirdPartyDefinition (definition: Cypress.ComponentFrameworkDefinition | Cypress.ThirdPartyComponentFrameworkDefinition): definition is Cypress.ThirdPartyComponentFrameworkDefinition {
28+
export function isThirdPartyDefinition (definition: Cypress.ComponentFrameworkDefinition | Cypress.ThirdPartyComponentFrameworkDefinition): boolean {
2929
return definition.type.startsWith(thirdPartyDefinitionPrefixes.globalPrefix) ||
3030
thirdPartyDefinitionPrefixes.namespacedPrefixRe.test(definition.type)
3131
}

packages/scaffold-config/src/frameworks.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -304,12 +304,13 @@ export function resolveComponentFrameworkDefinition (definition: Cypress.Compone
304304
if (thirdParty) {
305305
return {
306306
...definition,
307+
category: 'library',
307308
dependencies,
308309
configFramework: definition.type,
309310
supportStatus: 'community',
310311
mountModule: () => Promise.resolve(definition.type),
311312
}
312313
}
313314

314-
return { ...definition, dependencies }
315+
return { ...definition as Cypress.ComponentFrameworkDefinition, dependencies }
315316
}

0 commit comments

Comments
 (0)