Skip to content

[bug] Unknown encoding: base64url #361

Open

Description

@Le0X8
const NodeBuffer = require('node:buffer').Buffer;
const BrowserBuffer = require('buffer/').Buffer;

console.log(NodeBuffer.from('Hello, world!', 'utf8').toString('base64url')); // works
//> 'SGVsbG8sIHdvcmxkIQ'

console.log(BrowserBuffer.from('Hello, world!', 'utf8').toString('base64url')); // fails

Error:

Uncaught TypeError: Unknown encoding: base64url
    slowToString index.js:544
    toString index.js:606
    encode +page.svelte:41
    <anonymous> debugger eval code:1
[index.js:544:31](http://localhost:5173/node_modules/buffer/index.js)
    slowToString index.js:544
    toString index.js:606
    encode +page.svelte:41
    <anonymous> debugger eval code:1

This may break some stuff, so should be fixed soon!

Activity

  1. Le0X8 commented on May 28, 2024

    @Le0X8
    Author

    @feross please merge #314

  2. Pecacheu commented on Mar 18, 2026

    @Pecacheu

    This may break some stuff, so should be fixed soon!

    Hi, my library is 'stuff'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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