Skip to content

error in nextjs vercel edge runtime #3001

@MiraiTunga

Description

@MiraiTunga

Describe the bug
error occurs when an mathsjs function is used in nextjs vercel edge runtime

error Error [TypeError]: Argument to 'typed' at index 1 is not a (typed) function, nor an object with signatures as keys and functions as values.
    at <unknown> (webpack-internal:///(sc_server)/./node_modules/typed-function/lib/umd/typed-function.js:1784)
    at typed (webpack-internal:///(sc_server)/./node_modules/typed-function/lib/umd/typed-function.js:1779:31)
    at eval (webpack-internal:///(sc_server)/./node_modules/mathjs/lib/esm/function/arithmetic/unaryPlus.js:42:14)
    at assertAndCreate (webpack-internal:///(sc_server)/./node_modules/mathjs/lib/esm/utils/factory.js:45:16)
    at eval (webpack-internal:///(sc_server)/./node_modules/mathjs/lib/esm/entry/pureFunctionsAny.generated.js:616:99)

To Reproduce
use mathjs in nextjs vercel edge function

Important any mathsjs module in an nextjs edge function
You will get the error above

Does mathsjs use any of these unsupported APIs ?https://edge-runtime.vercel.sh/features/available-apis#unsupported-apis

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions