Skip to content

Commit

Permalink
fix: remove too strict convention
Browse files Browse the repository at this point in the history
  • Loading branch information
brillout committed Jun 5, 2024
1 parent 3104d29 commit bca93d1
Showing 1 changed file with 1 addition and 20 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ export { assertExtensionsConventions }

import pc from '@brillout/picocolors'
import { isObjectOfStrings } from '../../../../../utils/isObjectOfStrings.js'
import { PROJECT_VERSION, assert, assertUsage, assertWarning, findPackageJson, joinEnglish } from '../../../utils.js'
import { PROJECT_VERSION, assert, assertUsage, assertWarning, findPackageJson } from '../../../utils.js'
import { getConfigValueInterfaceFile, type InterfaceFile } from './getVikeConfig.js'
import path from 'path'
import semver from 'semver'
Expand Down Expand Up @@ -55,25 +55,6 @@ function assertExtensionsConventions(extendsConfig: ConfigFile, interfaceFile: I
{ onlyOnce: true }
)
}
if (extensionName.startsWith('vike-')) {
const prefix = [
//
'vike-react',
'vike-vue',
'vike-solid',
'vike-svelte',
'vike-angular',
'vike-preact'
]
assertWarning(
prefix.some((p) => extensionName === p || extensionName.startsWith(`${p}-`)),
`The name of the Vike extension ${pc.bold(extensionName)} should be or start with ${joinEnglish(
prefix.map(pc.bold),
'or'
)}.`,
{ onlyOnce: true }
)
}
}

function assertExtensionsPeerDependencies(interfaceFilesRelevantList: InterfaceFile[]) {
Expand Down

0 comments on commit bca93d1

Please sign in to comment.