Skip to content

Cloudflare Workers Compatibility #592

@gtlog

Description

@gtlog

Describe the bug
It is not possible to use this library within Cloudflare Workers due to lack of Node.js runtime. To be specific, lack of Buffer causes this error. As recommended by the Node documentation, likely an import is going to solve this problem.

To Reproduce
Steps to reproduce the behavior:

  1. Import farcaster-js within a Cloudflare Workers function
  2. Try to share a cast using the library

Expected behavior
We are expecting to cast on Farcaster.

Desktop (please complete the following information):

  • OS: macOS 13.2
  • Node version: 18.0
  • Code Version: latest

Additional context

Cloudflare Workers have compatibility flags for Node APIs. If Buffer can be imported from node:buffer, this problem is likely to be solved.

Metadata

Metadata

Assignees

No one assigned

    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