magic-string
npmv1.0.0TypeScriptModify strings, generate sourcemaps
Overview
magic-string is an npm package that modify strings, generate sourcemaps. It is extremely widely used, with about 153.8M downloads per week and 1 known dependents in the graph. The latest version is 1.0.0, released under the MIT license.
Who should use it
Teams working in the npm ecosystem who need modify strings, generate sourcemaps and value a battle-tested, widely-adopted solution.
When not to use it
Consider an alternative if you need to or if a more actively-maintained option better fits your npm stack.
Pros
- Large, well-established user base (153.8M weekly downloads).
- Ships TypeScript type definitions.
- Clear open-source license (MIT).
Cons
- No significant drawbacks detected from available metadata.
Auto-generated from collected registry metadata. No external claims are inferred.
Relationship graph
Dependencies (left) and dependents (right) of magic-string.
Dependencies
Runtime (1)
Dev (13)
Used by
Popular packages that depend on magic-string.
Native-ESM powered web dev build tool
A utility-first CSS framework for rapidly building custom user interfaces.
Next generation testing framework powered by Vite
@vue/compiler-sfc
Cybernetically enhanced web apps
Minimal H(TTP) framework built for high performance and portability.
A bson parser for node.js and the browser
Vitest snapshot manager
Vitest module mocker implementation
Browser running for Vitest
AST-aware v8-to-istanbul
Alternatives to magic-string
Encode/decode sourcemap mappings
Functions for dealing with a PostgreSQL connection string
Cybernetically enhanced web apps
Get the line and column number of a specific character in a string
prelude.ls is a functionally oriented utility library. It is powerful and flexible. Almost all of its functions are curried. It is written in, and is the recommended base library for, LiveScript.
Efficient implementation of Levenshtein algorithm with locale-specific collator support.
Returns true if a string has an extglob.
Converts a source-map from/to different formats and allows adding/changing properties.
Compare strings containing a mix of letters and numbers in the way a human being would in sort order.
Escape RegExp special characters
Returns `true` if the given string looks like a glob pattern or an extglob pattern. This makes it easy to create code that only uses external modules like node-glob when necessary, resulting in much faster code execution and initialization time, and a bet
Frequently installed together
TypeScript definitions for node
Native-ESM powered web dev build tool
Next generation testing framework powered by Vite
Universal filesystem path utils
Shared Vitest utility functions
An extremely fast JavaScript and CSS bundler and minifier.
Traverse an ESTree-compliant AST
Trace the original position through a source map
TypeScript definitions for estree
A JavaScript parser
Remap sequential sourcemaps through transformations to point at the original source code
ECMAScript parser
Version history
| Version | Published | License |
|---|---|---|
| 1.0.0latest | 3 days ago | MIT |
| 0.30.21 | 8 months ago | MIT |
| 0.30.19 | 10 months ago | MIT |
| 0.30.18 | 11 months ago | MIT |
| 0.30.17 | 1 year ago | MIT |
| 0.30.16 | 1 year ago | MIT |
| 0.30.15 | 1 year ago | MIT |
| 0.30.14 | 1 year ago | MIT |
| 0.30.13 | 1 year ago | MIT |
| 0.30.12 | 1 year ago | MIT |
| 0.30.11 | 2 years ago | MIT |
| 0.30.10 | 2 years ago | MIT |
| 0.30.9 | 2 years ago | MIT |
| 0.30.8 | 2 years ago | MIT |
| 0.30.7 | 2 years ago | MIT |
| 0.30.6 | 2 years ago | MIT |
| 0.30.5 | 2 years ago | MIT |
| 0.30.4 | 2 years ago | MIT |
| 0.30.3 | 2 years ago | MIT |
| 0.30.2 | 3 years ago | MIT |
Maintainers
Frequently asked questions
How do I install magic-string?
Run `npm install magic-string` to add magic-string to your npm project.
What license is magic-string released under?
magic-string is distributed under the MIT license.
How popular is magic-string?
magic-string has approximately 153,806,751 downloads per week and 1 known dependent packages.