Security News
GitHub Removes Malicious Pull Requests Targeting Open Source Repositories
GitHub removed 27 malicious pull requests attempting to inject harmful code across multiple open source repositories, in another round of low-effort attacks.
emmet-monaco-es
Advanced tools
Emmet Support for Monaco Editor
Compatible with Monaco Editor v0.22.0
and above.
If you are using old version of Monaco Editor, Please use v4.4.2
of this lib.
$ npm install emmet-monaco-es
The emmet
functionality was bind to language features not to a specific editor instance.
emmetHTML
works for HTML
compatible languages, like PHP
emmetCSS
works for CSS
compatible languages, like LESS
/ SCSS
emmetJSX
works for JSX
compatible languages, like TypeScript
Follow this guide to make Monaco Editor support TSX
import { emmetHTML, emmetCSS, emmetJSX, expandHTML, expandCSS } from "emmet-monaco-es";
// `emmetHTML` , `emmetCSS` and `emmetJSX` are used the same way
const dispose = emmetHTML(
// monaco-editor it self. If not provided, will use window.monaco instead.
// This could make the plugin support both ESM and AMD loaded monaco-editor
monaco,
// languages needs to support html markup emmet
['html', 'php']
);
// run it if you want to dispose emmetHTML.
// NOTE: all languages specified will be disposed.
dispose();
// internal expand API, if you want to extend functionality with emmet
expandHTML('a'); // <a href="${1}">${2}</a>
expandCSS('fz14'); // font-size: 14px;
<script src="https://unpkg.com/emmet-monaco-es/dist/emmet-monaco.min.js"></script>
<script>
// NOTE: monaco-editor should be loaded first
// see above esm example for details
emmetMonaco.emmetHTML(monaco);
</script>
Does NOT support Emmet for embed CSS inside HTML / JSX / TSX
MIT
FAQs
emmet plugin for monaco-editor
The npm package emmet-monaco-es receives a total of 558 weekly downloads. As such, emmet-monaco-es popularity was classified as not popular.
We found that emmet-monaco-es demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
GitHub removed 27 malicious pull requests attempting to inject harmful code across multiple open source repositories, in another round of low-effort attacks.
Security News
RubyGems.org has added a new "maintainer" role that allows for publishing new versions of gems. This new permission type is aimed at improving security for gem owners and the service overall.
Security News
Node.js will be enforcing stricter semver-major PR policies a month before major releases to enhance stability and ensure reliable release candidates.