Skip to content

Browser support? #141

Closed
Closed

Description

@asimpletune

Hi folks, I'm having some trouble running assertive-ts/core in a browser environment. I thought this was possible but maybe I'm misunderstanding something?

This library is designed to work in the browser and in Node.js.

I'm trying to use this in a Cloudflare Worker, which is a v8 environment, but when I test locally I receive this error

✘ [ERROR] Build failed with 2 errors:

✘ [ERROR] Could not resolve "assert/strict"

node_modules/@assertive-ts/core/dist/index.js:11:23:
   11 │ var strict_1 = require("assert/strict");

Which seems like a dependency on node's assert... although I'm probably mistaken about this.

In any case, could somebody potentially lend a hand and explain how the library is meant to be used in a browser? thanks!

Activity

  1. suany0805 commented on Apr 3, 2025

    @suany0805
    Contributor

    Hi @asimpletune.
    Currently, assertive does not include browser support 😞. However, we are considering adding it in the future. Apologies for any confusion, and thank you for your patience!

    Let us know if you have any other questions or suggestions.

  2. added a commit that references this issue on Apr 3, 2025
  3. asimpletune commented on Apr 3, 2025

    @asimpletune
    ContributorAuthor

    Got it @suany0805 . Just submitted a PR to remove browser support from the project's README #149 so the issue can be closed.

  4. self-assigned this
    on Apr 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions