question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Uncaught TypeError in Getting Started guide

See original GitHub issue

Hello Aleph.js team 👋. I was recently updating my blog post about Aleph and found that I was getting an error when following along with the current Getting Started guide. All three aleph commands, dev, start, and build result in the same error.

Commands entered:

deno install --unstable -A -f -n aleph https://deno.land/x/aleph@v0.2.28/cli.ts
export PATH="/Users/ajcwebdev/.deno/bin:$PATH"
aleph init hello
cd hello
aleph dev

Error output:

Check https://deno.land/x/aleph@v0.2.28/cli/dev.ts

error: Uncaught (in promise) TypeError: TS2345 [ERROR]: Argument of type 'TransformerFactory<SourceFile>' is not assignable to parameter of type 'TransformerFactory<SourceFile> | CustomTransformerFactory'.
  Type 'import("https://cdn.esm.sh/v41/typescript@4.2.4/lib/typescript.d.ts").TransformerFactory<import("https://cdn.esm.sh/v41/typescript@4.2.4/lib/typescript.d.ts").SourceFile>' is not assignable to type 'import("https://cdn.esm.sh/v41/typescript@4.1.2/lib/typescript.d.ts").TransformerFactory<import("https://cdn.esm.sh/v41/typescript@4.1.2/lib/typescript.d.ts").SourceFile>'.
    Types of parameters 'context' and 'context' are incompatible.
      Type 'import("https://cdn.esm.sh/v41/typescript@4.1.2/lib/typescript.d.ts").TransformationContext' is not assignable to type 'import("https://cdn.esm.sh/v41/typescript@4.2.4/lib/typescript.d.ts").TransformationContext'.
        The types of 'factory.createTypeParameterDeclaration(...).parent' are incompatible between these types.
          Type 'import("https://cdn.esm.sh/v41/typescript@4.1.2/lib/typescript.d.ts").DeclarationWithTypeParameterChildren | import("https://cdn.esm.sh/v41/typescript@4.1.2/lib/typescript.d.ts").InferTypeNode' is not assignable to type 'import("https://cdn.esm.sh/v41/typescript@4.2.4/lib/typescript.d.ts").DeclarationWithTypeParameterChildren | import("https://cdn.esm.sh/v41/typescript@4.2.4/lib/typescript.d.ts").InferTypeNode'.
            Type 'JSDocTemplateTag' is not assignable to type 'DeclarationWithTypeParameterChildren | InferTypeNode'.
              Type 'import("https://cdn.esm.sh/v41/typescript@4.1.2/lib/typescript.d.ts").JSDocTemplateTag' is not assignable to type 'import("https://cdn.esm.sh/v41/typescript@4.2.4/lib/typescript.d.ts").JSDocTemplateTag'.
                Types of property 'parent' are incompatible.
                  Type 'import("https://cdn.esm.sh/v41/typescript@4.1.2/lib/typescript.d.ts").JSDoc | import("https://cdn.esm.sh/v41/typescript@4.1.2/lib/typescript.d.ts").JSDocTypeLiteral' is not assignable to type 'import("https://cdn.esm.sh/v41/typescript@4.2.4/lib/typescript.d.ts").JSDoc | import("https://cdn.esm.sh/v41/typescript@4.2.4/lib/typescript.d.ts").JSDocTypeLiteral'.
                    Type 'JSDoc' is not assignable to type 'JSDoc | JSDocTypeLiteral'.
                      Type 'import("https://cdn.esm.sh/v41/typescript@4.1.2/lib/typescript.d.ts").JSDoc' is not assignable to type 'import("https://cdn.esm.sh/v41/typescript@4.2.4/lib/typescript.d.ts").JSDoc'.
                        Types of property 'parent' are incompatible.
                          Type 'import("https://cdn.esm.sh/v41/typescript@4.1.2/lib/typescript.d.ts").HasJSDoc' is not assignable to type 'import("https://cdn.esm.sh/v41/typescript@4.2.4/lib/typescript.d.ts").HasJSDoc'.
                            Type 'ImportEqualsDeclaration' is not assignable to type 'HasJSDoc'.
                              Property 'isTypeOnly' is missing in type 'import("https://cdn.esm.sh/v41/typescript@4.1.2/lib/typescript.d.ts").ImportEqualsDeclaration' but required in type 'import("https://cdn.esm.sh/v41/typescript@4.2.4/lib/typescript.d.ts").ImportEqualsDeclaration'.
    if (reactRefresh) transformers.before!.push(reactRefreshTS())
                                                ~~~~~~~~~~~~~~~~
    at https://deno.land/x/aleph@v0.2.28/tsc/compile.ts:28:49

    'isTypeOnly' is declared here.
            readonly isTypeOnly: boolean;
                     ~~~~~~~~~~
        at https://cdn.esm.sh/v41/typescript@4.2.4/lib/typescript.d.ts:1601:18
    const { default: cmd } = await import(`./cli/${command}.ts`)
                             ^
    at async main (https://deno.land/x/aleph@v0.2.28/cli.ts:163:30)

Aleph version

aleph.js v0.2.28

Deno version

deno 1.8.0

deno info

DENO_DIR location: "/Users/ajcwebdev/Library/Caches/deno"
Remote modules cache: "/Users/ajcwebdev/Library/Caches/deno/deps"
TypeScript compiler cache: "/Users/ajcwebdev/Library/Caches/deno/gen"

My system info

System Version: macOS 11.3 (20E232)
Kernel Version: Darwin 20.4.0
Boot Volume: Macintosh HD

Hopefully that’s helpful, let me know if you need other system info or anything like that.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:23 (7 by maintainers)

github_iconTop GitHub Comments

3reactions
shadowtime2000commented, May 29, 2021

Documentation is way behind on things

@thesabbir I would like to point out that the doc is purposely not updated with alpha stuff, well, because its alpha and super unstable compared to 0.2.28.

@scally Awesome!

1reaction
ajcwebdevcommented, May 29, 2021

Cool, thanks for the info @shadowtime2000! 👍

Haven’t tried it yet but it looks like there is in fact a dvm.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How To Fix the "uncaught typeerror: cannot read property ...
In this tutorial, we'll talk about one of the most common JavaScript errors — the “uncaught typeerror: cannot read property” error.
Read more >
How to Handle JavaScript Uncaught TypeError: “x” is Not a ...
The Javascript TypeError: "x" is not a function occurs when calling a function on a value or object, which is not actually a...
Read more >
Three.js error Uncaught TypeError following a guide
And I got the three.min.js from the official three.js download folder and I have put it the html directory. I am getting this...
Read more >
Uncaught TypeError : Cannot read properties of undefined
Looking for ways to handle Uncaught TypeError: Cannot read property of undefined in JavaScript? This guide will help you to catch errors.
Read more >
Uncaught TypeError: Cannot read property 'call' of undefined ...
Using d93604d and following the steps from the "getting started" guide: degit sveltejs/sapper-template my-app cd my-app npm install npm run ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found