我从github上下载了cocos3.8.3的源码,根据文档下载依赖库之后使用,运行npm install命令有一些红色的报错,
G:/cocos/cocos-engine-3.8.3/cocos/core/value-types/bitmask.ts (61,26): Type ‘T’ is not assignable to type ‘object’.
G:/cocos/cocos-engine-3.8.3/cocos/core/value-types/bitmask.ts (64,11): Argument of type ‘T’ is not assignable to parameter of type ‘Record<string | number, any>’.
G:/cocos/cocos-engine-3.8.3/cocos/core/value-types/bitmask.ts (67,40): No overload matches this call.
Overload 1 of 2, ‘(o: {}): string[]’, gave the following error.
Argument of type ‘T’ is not assignable to parameter of type ‘{}’.
Overload 2 of 2, ‘(o: object): string[]’, gave the following error.
Argument of type ‘T’ is not assignable to parameter of type ‘object’.
G:/cocos/cocos-engine-3.8.3/cocos/core/value-types/bitmask.ts (82,51): Type ‘T’ is not assignable to type ‘object’.
G:/cocos/cocos-engine-3.8.3/cocos/core/value-types/bitmask.ts (86,19): Argument of type ‘T’ is not assignable to parameter of type ‘Record<string | number, any>’.
G:/cocos/cocos-engine-3.8.3/cocos/core/value-types/enum.ts (50,24): Type ‘T’ is not assignable to type ‘object’.
G:/cocos/cocos-engine-3.8.3/cocos/core/value-types/enum.ts (53,11): Argument of type ‘T’ is not assignable to parameter of type ‘Record<string | number, any>’.
G:/cocos/cocos-engine-3.8.3/cocos/core/value-types/enum.ts (66,40): No overload matches this call.
Overload 1 of 2, ‘(o: {}): string[]’, gave the following error.
Argument of type ‘T’ is not assignable to parameter of type ‘{}’.
Overload 2 of 2, ‘(o: object): string[]’, gave the following error.
Argument of type ‘T’ is not assignable to parameter of type ‘object’.
G:/cocos/cocos-engine-3.8.3/cocos/core/value-types/enum.ts (81,51): Type ‘T’ is not assignable to type ‘object’.
G:/cocos/cocos-engine-3.8.3/cocos/core/value-types/enum.ts (85,19): Argument of type ‘T’ is not assignable to parameter of type ‘Record<string | number, any>’.
G:/cocos/cocos-engine-3.8.3/cocos/core/value-types/enum.ts (91,20): Argument of type ‘T’ is not assignable to parameter of type ‘{}’.
G:/cocos/cocos-engine-3.8.3/cocos/gfx/base/pipeline-state.editor.ts (322,12): Property ‘blendState’ in type ‘PassStatesEditor’ is not assignable to the same property in base type ‘IPassStates’.
Type ‘BlendStateEditor’ is missing the following properties from type ‘BlendState’: _token, native, setTarget, reset, destroy
It’s 2025/4/29 17:23:46, we’re still doing the hack for spine-core.d.ts
Bundling…
DeprecationWarning: ‘’ has been deprecated since v4.0.0. Use the appropriate method on ‘ts.factory’ or the ‘factory’ supplied by your transformation context instead.
Failed to resolve type import("…/foundation/node-shell").NodeInputPath, There is no symbol info.
DeprecationWarning: ‘createIndexSignature’ has been deprecated since v4.8.0. Decorators are no longer supported for this function. Callers should switch to an overload that does not accept a ‘decorators’ parameter.
Don’t know how to handle type #${string}(Syntax Kind: TemplateLiteralType)
Failed to resolve type import(‘pal/audio/type’).AudioLoadOptions, There is no symbol info.
Failed to resolve type import(‘pal/audio/type’).AudioLoadOptions, There is no symbol info.
Failed to resolve type import(‘pal/audio/type’).AudioLoadOptions, There is no symbol info.
Failed to resolve type import(‘pal/audio/type’).AudioType, There is no symbol info.
Failed to resolve type import(‘pal/audio/type’).AudioState, There is no symbol info.
Failed to resolve type import(‘pal/audio/type’).AudioPCMDataView, There is no symbol info.
Don’t know how to handle type ${x}(Syntax Kind: TemplateLiteralType)
Don’t know how to handle type ${x}(Syntax Kind: TemplateLiteralType)
Failed to resolve type import(‘pal/input/input-source’).InputSourceButton, There is no symbol info.
Failed to resolve type import(‘pal/input/input-source’).InputSourceDpad, There is no symbol info.
Failed to resolve type import(‘pal/input/input-source’).InputSourceStick, There is no symbol info.
Failed to resolve type import(‘pal/input/input-source’).InputSourcePosition, There is no symbol info.
Failed to resolve type import(‘pal/input/input-source’).InputSourceOrientation, There is no symbol info.
cocos-creator@3.8.3 build:adapter
node ./scripts/build-adapter.js
我不知道这个是打印还是真的有什么问题。