Git Product home page Git Product logo

Comments (8)

Jiralite avatar Jiralite commented on September 24, 2024

Update TypeScript to at least 5.1.3.

from discord.js.

GravityScriptsV2 avatar GravityScriptsV2 commented on September 24, 2024

Same thing still happens. ive upgraded my typescript to 5.1.3 and all the errors still appearing when trying to build into js

from discord.js.

Jiralite avatar Jiralite commented on September 24, 2024

That's impossible. Double-check your installations, your versions, etc.

from discord.js.

GravityScriptsV2 avatar GravityScriptsV2 commented on September 24, 2024

I have.

C:\Users\Gravity\Downloads\Venoxity Development\Venoxity-Utilities>npm run build

> [email protected] build
> tsc

node_modules/discord.js/typings/index.d.ts:1210:21 - error TS1139: Type parameter declaration expected.

1210   public getChannel<const Type extends ChannelType = ChannelType>(
                         ~~~~~

node_modules/discord.js/typings/index.d.ts:1210:27 - error TS1435: Unknown keyword or identifier. Did you mean 'type'?

1210   public getChannel<const Type extends ChannelType = ChannelType>(
                               ~~~~

node_modules/discord.js/typings/index.d.ts:1210:32 - error TS1068: Unexpected token. A constructor, method, accessor, or property was expected.

1210   public getChannel<const Type extends ChannelType = ChannelType>(
                                    ~~~~~~~

node_modules/discord.js/typings/index.d.ts:1211:9 - error TS1005: ')' expected.

1211     name: string,
             ~

node_modules/discord.js/typings/index.d.ts:1211:11 - error TS1068: Unexpected token. A constructor, method, accessor, or property was expected.

1211     name: string,
               ~~~~~~

node_modules/discord.js/typings/index.d.ts:1212:13 - error TS1005: ';' expected.

1212     required: true,
                 ~

node_modules/discord.js/typings/index.d.ts:1213:18 - error TS1109: Expression expected.

1213     channelTypes?: readonly Type[],
                      ~

node_modules/discord.js/typings/index.d.ts:1213:29 - error TS1005: ';' expected.

1213     channelTypes?: readonly Type[],
                                 ~~~~

node_modules/discord.js/typings/index.d.ts:1213:34 - error TS1011: An element access expression should take an argument.

1213     channelTypes?: readonly Type[],


node_modules/discord.js/typings/index.d.ts:1214:3 - error TS1109: Expression expected.

1214   ): Extract<
       ~

node_modules/discord.js/typings/index.d.ts:1214:4 - error TS1128: Declaration or statement expected.

1214   ): Extract<
        ~

node_modules/discord.js/typings/index.d.ts:1225:3 - error TS1128: Declaration or statement expected.

1225   public getChannel<const Type extends ChannelType = ChannelType>(
       ~~~~~~

node_modules/discord.js/typings/index.d.ts:1225:21 - error TS1109: Expression expected.

1225   public getChannel<const Type extends ChannelType = ChannelType>(
                         ~~~~~

node_modules/discord.js/typings/index.d.ts:1225:32 - error TS1005: ',' expected.

1225   public getChannel<const Type extends ChannelType = ChannelType>(
                                    ~~~~~~~

node_modules/discord.js/typings/index.d.ts:1226:9 - error TS1005: ')' expected.

1226     name: string,
             ~

node_modules/discord.js/typings/index.d.ts:1227:13 - error TS1005: ',' expected.

1227     required?: boolean,
                 ~

node_modules/discord.js/typings/index.d.ts:1227:14 - error TS1134: Variable declaration expected.

1227     required?: boolean,
                  ~

node_modules/discord.js/typings/index.d.ts:1228:17 - error TS1005: ',' expected.

1228     channelTypes?: readonly Type[],
                     ~

node_modules/discord.js/typings/index.d.ts:1228:18 - error TS1134: Variable declaration expected.

1228     channelTypes?: readonly Type[],
                      ~

node_modules/discord.js/typings/index.d.ts:1228:29 - error TS1005: ',' expected.

1228     channelTypes?: readonly Type[],
                                 ~~~~

node_modules/discord.js/typings/index.d.ts:1228:33 - error TS1005: ',' expected.

1228     channelTypes?: readonly Type[],
                                     ~

node_modules/discord.js/typings/index.d.ts:1229:3 - error TS1128: Declaration or statement expected.

1229   ): Extract<
       ~

node_modules/discord.js/typings/index.d.ts:1229:4 - error TS1128: Declaration or statement expected.

1229   ): Extract<
        ~

node_modules/discord.js/typings/index.d.ts:1240:3 - error TS1128: Declaration or statement expected.

1240   public getString(name: string, required: true): string;
       ~~~~~~

node_modules/discord.js/typings/index.d.ts:1240:24 - error TS1005: ',' expected.

1240   public getString(name: string, required: true): string;
                            ~

node_modules/discord.js/typings/index.d.ts:1240:42 - error TS1005: ',' expected.

1240   public getString(name: string, required: true): string;
                                              ~

node_modules/discord.js/typings/index.d.ts:1240:49 - error TS1005: ';' expected.

1240   public getString(name: string, required: true): string;
                                                     ~

node_modules/discord.js/typings/index.d.ts:1241:3 - error TS1128: Declaration or statement expected.

1241   public getString(name: string, required?: boolean): string | null;
       ~~~~~~

node_modules/discord.js/typings/index.d.ts:1241:24 - error TS1005: ',' expected.

1241   public getString(name: string, required?: boolean): string | null;
                            ~

node_modules/discord.js/typings/index.d.ts:1241:43 - error TS1109: Expression expected.

1241   public getString(name: string, required?: boolean): string | null;
                                               ~

node_modules/discord.js/typings/index.d.ts:1241:53 - error TS1005: ';' expected.

1241   public getString(name: string, required?: boolean): string | null;
                                                         ~

node_modules/discord.js/typings/index.d.ts:1242:3 - error TS1128: Declaration or statement expected.

1242   public getInteger(name: string, required: true): number;
       ~~~~~~

node_modules/discord.js/typings/index.d.ts:1242:25 - error TS1005: ',' expected.

1242   public getInteger(name: string, required: true): number;
                             ~

node_modules/discord.js/typings/index.d.ts:1242:43 - error TS1005: ',' expected.

1242   public getInteger(name: string, required: true): number;
                                               ~

node_modules/discord.js/typings/index.d.ts:1242:50 - error TS1005: ';' expected.

1242   public getInteger(name: string, required: true): number;
                                                      ~

node_modules/discord.js/typings/index.d.ts:1243:3 - error TS1128: Declaration or statement expected.

1243   public getInteger(name: string, required?: boolean): number | null;
       ~~~~~~

node_modules/discord.js/typings/index.d.ts:1243:25 - error TS1005: ',' expected.

1243   public getInteger(name: string, required?: boolean): number | null;
                             ~

node_modules/discord.js/typings/index.d.ts:1243:44 - error TS1109: Expression expected.

1243   public getInteger(name: string, required?: boolean): number | null;
                                                ~

node_modules/discord.js/typings/index.d.ts:1243:54 - error TS1005: ';' expected.

1243   public getInteger(name: string, required?: boolean): number | null;
                                                          ~

node_modules/discord.js/typings/index.d.ts:1244:3 - error TS1128: Declaration or statement expected.

1244   public getNumber(name: string, required: true): number;
       ~~~~~~

node_modules/discord.js/typings/index.d.ts:1244:24 - error TS1005: ',' expected.

1244   public getNumber(name: string, required: true): number;
                            ~

node_modules/discord.js/typings/index.d.ts:1244:42 - error TS1005: ',' expected.

1244   public getNumber(name: string, required: true): number;
                                              ~

node_modules/discord.js/typings/index.d.ts:1244:49 - error TS1005: ';' expected.

1244   public getNumber(name: string, required: true): number;
                                                     ~

node_modules/discord.js/typings/index.d.ts:1245:3 - error TS1128: Declaration or statement expected.

1245   public getNumber(name: string, required?: boolean): number | null;
       ~~~~~~

node_modules/discord.js/typings/index.d.ts:1245:24 - error TS1005: ',' expected.

1245   public getNumber(name: string, required?: boolean): number | null;
                            ~

node_modules/discord.js/typings/index.d.ts:1245:43 - error TS1109: Expression expected.

1245   public getNumber(name: string, required?: boolean): number | null;
                                               ~

node_modules/discord.js/typings/index.d.ts:1245:53 - error TS1005: ';' expected.

1245   public getNumber(name: string, required?: boolean): number | null;
                                                         ~

node_modules/discord.js/typings/index.d.ts:1246:3 - error TS1128: Declaration or statement expected.

1246   public getUser(name: string, required: true): NonNullable<CommandInteractionOption<Cached>['user']>;
       ~~~~~~

node_modules/discord.js/typings/index.d.ts:1246:22 - error TS1005: ',' expected.

1246   public getUser(name: string, required: true): NonNullable<CommandInteractionOption<Cached>['user']>;
                          ~

node_modules/discord.js/typings/index.d.ts:1246:40 - error TS1005: ',' expected.

1246   public getUser(name: string, required: true): NonNullable<CommandInteractionOption<Cached>['user']>;
                                            ~

node_modules/discord.js/typings/index.d.ts:1246:47 - error TS1005: ';' expected.

1246   public getUser(name: string, required: true): NonNullable<CommandInteractionOption<Cached>['user']>;
                                                   ~

node_modules/discord.js/typings/index.d.ts:1247:3 - error TS1128: Declaration or statement expected.

1247   public getUser(name: string, required?: boolean): NonNullable<CommandInteractionOption<Cached>['user']> | null;
       ~~~~~~

node_modules/discord.js/typings/index.d.ts:1247:22 - error TS1005: ',' expected.

1247   public getUser(name: string, required?: boolean): NonNullable<CommandInteractionOption<Cached>['user']> | null;
                          ~

node_modules/discord.js/typings/index.d.ts:1247:41 - error TS1109: Expression expected.

1247   public getUser(name: string, required?: boolean): NonNullable<CommandInteractionOption<Cached>['user']> | null;
                                             ~

node_modules/discord.js/typings/index.d.ts:1247:51 - error TS1005: ';' expected.

1247   public getUser(name: string, required?: boolean): NonNullable<CommandInteractionOption<Cached>['user']> | null;
                                                       ~

node_modules/discord.js/typings/index.d.ts:1248:3 - error TS1128: Declaration or statement expected.

1248   public getMember(name: string): NonNullable<CommandInteractionOption<Cached>['member']> | null;
       ~~~~~~

node_modules/discord.js/typings/index.d.ts:1248:24 - error TS1005: ',' expected.

1248   public getMember(name: string): NonNullable<CommandInteractionOption<Cached>['member']> | null;
                            ~

node_modules/discord.js/typings/index.d.ts:1248:33 - error TS1005: ';' expected.

1248   public getMember(name: string): NonNullable<CommandInteractionOption<Cached>['member']> | null;
                                     ~

node_modules/discord.js/typings/index.d.ts:1249:3 - error TS1128: Declaration or statement expected.

1249   public getRole(name: string, required: true): NonNullable<CommandInteractionOption<Cached>['role']>;
       ~~~~~~

node_modules/discord.js/typings/index.d.ts:1249:22 - error TS1005: ',' expected.

1249   public getRole(name: string, required: true): NonNullable<CommandInteractionOption<Cached>['role']>;
                          ~

node_modules/discord.js/typings/index.d.ts:1249:40 - error TS1005: ',' expected.

1249   public getRole(name: string, required: true): NonNullable<CommandInteractionOption<Cached>['role']>;
                                            ~

node_modules/discord.js/typings/index.d.ts:1249:47 - error TS1005: ';' expected.

1249   public getRole(name: string, required: true): NonNullable<CommandInteractionOption<Cached>['role']>;
                                                   ~

node_modules/discord.js/typings/index.d.ts:1250:3 - error TS1128: Declaration or statement expected.

1250   public getRole(name: string, required?: boolean): NonNullable<CommandInteractionOption<Cached>['role']> | null;
       ~~~~~~

node_modules/discord.js/typings/index.d.ts:1250:22 - error TS1005: ',' expected.

1250   public getRole(name: string, required?: boolean): NonNullable<CommandInteractionOption<Cached>['role']> | null;
                          ~

node_modules/discord.js/typings/index.d.ts:1250:41 - error TS1109: Expression expected.

1250   public getRole(name: string, required?: boolean): NonNullable<CommandInteractionOption<Cached>['role']> | null;
                                             ~

node_modules/discord.js/typings/index.d.ts:1250:51 - error TS1005: ';' expected.

1250   public getRole(name: string, required?: boolean): NonNullable<CommandInteractionOption<Cached>['role']> | null;
                                                       ~

node_modules/discord.js/typings/index.d.ts:1251:3 - error TS1128: Declaration or statement expected.

1251   public getAttachment(name: string, required: true): NonNullable<CommandInteractionOption<Cached>['attachment']>;
       ~~~~~~

node_modules/discord.js/typings/index.d.ts:1251:28 - error TS1005: ',' expected.

1251   public getAttachment(name: string, required: true): NonNullable<CommandInteractionOption<Cached>['attachment']>;
                                ~

node_modules/discord.js/typings/index.d.ts:1251:46 - error TS1005: ',' expected.

1251   public getAttachment(name: string, required: true): NonNullable<CommandInteractionOption<Cached>['attachment']>;
                                                  ~

node_modules/discord.js/typings/index.d.ts:1251:53 - error TS1005: ';' expected.

1251   public getAttachment(name: string, required: true): NonNullable<CommandInteractionOption<Cached>['attachment']>;
                                                         ~

node_modules/discord.js/typings/index.d.ts:1252:3 - error TS1128: Declaration or statement expected.

1252   public getAttachment(
       ~~~~~~

node_modules/discord.js/typings/index.d.ts:1253:9 - error TS1005: ',' expected.

1253     name: string,
             ~

node_modules/discord.js/typings/index.d.ts:1254:14 - error TS1109: Expression expected.

1254     required?: boolean,
                  ~

node_modules/discord.js/typings/index.d.ts:1255:4 - error TS1005: ';' expected.

1255   ): NonNullable<CommandInteractionOption<Cached>['attachment']> | null;
        ~

node_modules/discord.js/typings/index.d.ts:1256:3 - error TS1128: Declaration or statement expected.

1256   public getMentionable(
       ~~~~~~

node_modules/discord.js/typings/index.d.ts:1257:9 - error TS1005: ',' expected.

1257     name: string,
             ~

node_modules/discord.js/typings/index.d.ts:1258:13 - error TS1005: ',' expected.

1258     required: true,
                 ~

node_modules/discord.js/typings/index.d.ts:1259:4 - error TS1005: ';' expected.

1259   ): NonNullable<CommandInteractionOption<Cached>['member' | 'role' | 'user']>;
        ~

node_modules/discord.js/typings/index.d.ts:1260:3 - error TS1128: Declaration or statement expected.

1260   public getMentionable(
       ~~~~~~

node_modules/discord.js/typings/index.d.ts:1261:9 - error TS1005: ',' expected.

1261     name: string,
             ~

node_modules/discord.js/typings/index.d.ts:1262:14 - error TS1109: Expression expected.

1262     required?: boolean,
                  ~

node_modules/discord.js/typings/index.d.ts:1263:4 - error TS1005: ';' expected.

1263   ): NonNullable<CommandInteractionOption<Cached>['member' | 'role' | 'user']> | null;
        ~

node_modules/discord.js/typings/index.d.ts:1264:3 - error TS1128: Declaration or statement expected.

1264   public getMessage(name: string, required: true): NonNullable<CommandInteractionOption<Cached>['message']>;
       ~~~~~~

node_modules/discord.js/typings/index.d.ts:1264:25 - error TS1005: ',' expected.

1264   public getMessage(name: string, required: true): NonNullable<CommandInteractionOption<Cached>['message']>;
                             ~

node_modules/discord.js/typings/index.d.ts:1264:43 - error TS1005: ',' expected.

1264   public getMessage(name: string, required: true): NonNullable<CommandInteractionOption<Cached>['message']>;
                                               ~

node_modules/discord.js/typings/index.d.ts:1264:50 - error TS1005: ';' expected.

1264   public getMessage(name: string, required: true): NonNullable<CommandInteractionOption<Cached>['message']>;
                                                      ~

node_modules/discord.js/typings/index.d.ts:1265:3 - error TS1128: Declaration or statement expected.

1265   public getMessage(name: string, required?: boolean): NonNullable<CommandInteractionOption<Cached>['message']> | null;
       ~~~~~~

node_modules/discord.js/typings/index.d.ts:1265:25 - error TS1005: ',' expected.

1265   public getMessage(name: string, required?: boolean): NonNullable<CommandInteractionOption<Cached>['message']> | null;
                             ~

node_modules/discord.js/typings/index.d.ts:1265:44 - error TS1109: Expression expected.

1265   public getMessage(name: string, required?: boolean): NonNullable<CommandInteractionOption<Cached>['message']> | null;
                                                ~

node_modules/discord.js/typings/index.d.ts:1265:54 - error TS1005: ';' expected.

1265   public getMessage(name: string, required?: boolean): NonNullable<CommandInteractionOption<Cached>['message']> | null;
                                                          ~

node_modules/discord.js/typings/index.d.ts:1266:3 - error TS1128: Declaration or statement expected.

1266   public getFocused(getFull: true): AutocompleteFocusedOption;
       ~~~~~~

node_modules/discord.js/typings/index.d.ts:1266:28 - error TS1005: ',' expected.

1266   public getFocused(getFull: true): AutocompleteFocusedOption;
                                ~

node_modules/discord.js/typings/index.d.ts:1266:35 - error TS1005: ';' expected.

1266   public getFocused(getFull: true): AutocompleteFocusedOption;
                                       ~

node_modules/discord.js/typings/index.d.ts:1267:3 - error TS1128: Declaration or statement expected.

1267   public getFocused(getFull?: boolean): string;
       ~~~~~~

node_modules/discord.js/typings/index.d.ts:1267:29 - error TS1109: Expression expected.

1267   public getFocused(getFull?: boolean): string;
                                 ~

node_modules/discord.js/typings/index.d.ts:1267:39 - error TS1005: ';' expected.

1267   public getFocused(getFull?: boolean): string;
                                           ~

node_modules/discord.js/typings/index.d.ts:1268:1 - error TS1128: Declaration or statement expected.

1268 }
     ~


Found 97 errors in the same file, starting at: node_modules/discord.js/typings/index.d.ts:1210


C:\Users\Gravity\Downloads\Venoxity Development\Venoxity-Utilities>tsc --v
Version 5.1.3

C:\Users\Gravity\Downloads\Venoxity Development\Venoxity-Utilities>

from discord.js.

Jiralite avatar Jiralite commented on September 24, 2024

Running tsc --v isn't scoped to the package. Your package is using a different version.

from discord.js.

GravityScriptsV2 avatar GravityScriptsV2 commented on September 24, 2024

Running tsc --v isn't scoped to the package. Your package is using a different version.

I have it globally installed didnt know you had to install it inside the package itself

from discord.js.

GravityScriptsV2 avatar GravityScriptsV2 commented on September 24, 2024

That fixed it thanks

from discord.js.

Jiralite avatar Jiralite commented on September 24, 2024

I have it globally installed didnt know you had to install it inside the package itself

You do not need to. I suggested that because it seemed like a case of confusing global dependencies with what's actually being used in your project. I would recommend installing TypeScript as a development dependency in projects though.

from discord.js.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.