详细说明: - 添加了V2版本的工作流页面和结果页面 - 更新了Serena记忆文件 - 添加了详细实施计划文档 - 优化了Vite配置 - 更新了项目文档CLAUDE.md - 构建了演示系统的dist版本 - 包含了exhibition-demo的完整依赖
decode-named-character-reference
Decode named character references.
Contents
- What is this?
- When should I use this?
- Install
- Use
- API
- Types
- Compatibility
- Security
- Related
- Contribute
- License
What is this?
A workaround for webpack.
When should I use this?
Never use this.
Use parse-entities.
It uses this.
Install
This package is ESM only. In Node.js (version 14.14+, 16.0+), install with npm:
npm install decode-named-character-reference
In Deno with esm.sh:
import {decodeNamedCharacterReference} from 'https://esm.sh/decode-named-character-reference@1'
In browsers with esm.sh:
<script type="module">
import {decodeNamedCharacterReference} from 'https://esm.sh/decode-named-character-reference@1?bundle'
</script>
Use
import {decodeNamedCharacterReference} from 'decode-named-character-reference'
decodeNamedCharacterReference('amp') //=> '&'
API
This package exports the identifier decodeNamedCharacterReference.
There is no default export.
decodeNamedCharacterReference(value)
Again, use parse-entities.
Types
This package is fully typed with TypeScript. It exports no additional types.
Compatibility
This package is at least compatible with all maintained versions of Node.js. As of now, that is Node.js 14.14+ and 16.0+. It also works in Deno and modern browsers.
Security
This package is safe.
Related
parse-entities— parse (decode) HTML character references
Contribute
Yes please! See How to Contribute to Open Source.