Comments (3)
@huw That actually already exists, its available in cbor-x/dist/index-no-eval.cjs (and decode-only variant as well).
I suppose you might run into problems importing, I should probably add those to the exports of the cbor-x package as well.
from cbor-x.
Ah--that's embarrassing! I should've read through the docs a bit more thoroughly.
Thanks for adding the variants though, that should make things a bit easier :) (no compilation issues on my side though)
from cbor-x.
Hi, sorry to revive this but I had trouble using cbor-x in Cloudflare Workers, as well, and stumbled upon this issue. After importing cbor-x/dist/index-no-eval
all that really came from that is that I would get a:
(error) ReferenceError: BlockedFunction is not defined
I'm not really sure what I'm doing wrong here. Additionally, the no-eval variants seem to not work at all work with TypeScript.
@huw's workaround worked fine for me. however, I'd rather not be in the habit of modifying node_modules
if I can help it.
from cbor-x.
Related Issues (20)
- Encoder options for record extension HOT 5
- Sort record keys HOT 2
- better structured clone support HOT 4
- Global namespace pollution; `stringRefs` ? HOT 3
- No encoding support for 64 bit format integers HOT 5
- [Feature]: Generate blob parts to support embedding blobs (aka files) HOT 27
- sorting HOT 2
- Distribute ESM HOT 3
- Unknown tag with map value decode issue HOT 2
- Is there a registered media type for when using the structured clone extension HOT 2
- Edge case with nested records sharing the same keys HOT 4
- SuperJSONatural - New kid in the game worth to take a look at it
- How to use with Axios? HOT 2
- cbor-x doesn't support integer keys HOT 4
- safeKey in cbor-x encode / decode HOT 4
- null is not an object (evaluating 'TypedArray.BYTES_PER_ELEMENT HOT 5
- Provide an option to force encoding numbers as double
- globalThis not available on older Safari versions HOT 3
- TypeError: encode is not a function HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from cbor-x.