1.0.0 • Published 2 years ago

@ct-note/inline-code v1.0.0

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

npm.io

InlineCode Tool

Inline Tool for marking code-fragments for the Editor.js.

npm.io

Installation

Install via NPM

Get the package

npm i --save-dev @editorjs/inline-code

Include module at your application

const InlineCode = require('@editorjs/inline-code');

Download to your project's source dir

  1. Upload folder dist from repository
  2. Add dist/bundle.js file to your page.

Load from CDN

You can load specific version of package from jsDelivr CDN.

https://cdn.jsdelivr.net/npm/@editorjs/inline-code@1.0.1

Require this script on a page with Editor.js.

<script src="..."></script>

Usage

Add a new Tool to the tools property of the Editor.js initial config.

var editor = EditorJS({
  ...
  
  tools: {
    ...
    inlineCode: {
      class: InlineCode,
      shortcut: 'CMD+SHIFT+M',
    },
  },
  
  ...
});

Config Params

This Tool has no config params

Output data

Marked text will be wrapped with a span tag with an inline-code class.

{
    "type" : "text",
    "data" : {
        "text" : "Create a directory for your module, enter it and run <span class=\"inline-code\">npm init</span> command."
    }
}
acorn-dynamic-importacornajv-keywordsajvansi-regexansi-stylesajv-errorsanymatcharr-unionaprobaarray-uniquearr-diffarr-flattenasn1.jsassertassign-symbolsasync-eachatobbabel-code-framebalanced-matchbase64-jsbasebig.jsbn.jsbrace-expansionbluebirdbinary-extensionsbracesbrowserify-aesbrowserify-cipherbrorandbrowserify-rsabrowserify-desbrowserify-signbrowserify-zlibbrowserslistbufferbuffer-fromcacachebuiltin-status-codesbuffer-xorcache-basecaniuse-litechalkchokidarcamelcasechownrchrome-trace-eventcipher-baseclass-utilscliuicode-point-atcollection-visitcolor-convertcommandercolorettecolor-namecomponent-emitterconcat-mapcommondirconcat-streamconsole-browserifyconstants-browserifyconvert-source-mapcopy-descriptorcore-util-iscreate-ecdhcopy-concurrentlycreate-hmaccreate-hashcross-spawncrypto-browserifycyclistcssesccss-selector-tokenizerdecode-uri-componentdebugdate-nowdefine-propertiesdecamelizedetect-filedes.jsdefine-propertydiffie-hellmandomain-browseremojis-listelectron-to-chromiumduplexifyend-of-streamenhanced-resolvees-abstracterrnoelliptices-to-primitiveescaladeeslint-scopeescape-string-regexpesrecurseevp_bytestokeyeventsesutilsestraverseexpand-bracketsexpand-tildeexecaextend-shallowextglobfast-deep-equalfast-json-stable-stringifyfastparsefiggy-puddingfill-rangefind-cache-dirflush-write-streamfind-upfragment-cachefindup-syncfor-infrom2fs-write-stream-atomicfs.realpathfunction-bindget-caller-fileget-valueglobglobal-prefixget-streamglob-parentglobal-modulesglobalsgraceful-fshashas-ansihas-flaghas-symbolshas-valueshas-valuehash.jshash-basehmac-drbghomedir-polyfillhttps-browserifyieee754icss-utilsicss-replace-symbolsiferrindexofimport-localimurmurhashinheritsinflightiniinterpretinvariantinvert-kvis-binary-pathis-accessor-descriptoris-callableis-bufferis-data-descriptoris-date-objectis-descriptoris-extendableis-extglobis-fullwidth-code-pointis-globis-numberis-plain-objectis-regexis-streamis-symbolis-windowsisarrayisexejs-levenshteinjs-tokensisobjectjsescjson5json-parse-better-errorsjson-schema-traverselcidloader-runnerkind-oflocate-pathloader-utilsloose-envifylru-cachelodashmake-dirmamacromap-age-cleanermap-cachemd5.jsmap-visitmemmemory-fsmicromatchmimic-fnmiller-rabinminimalistic-crypto-utilsminimalistic-assertminimatchminimistmississippimixin-deepmove-concurrentlymkdirpmsnanomatchneo-asyncnice-trynormalize-pathnode-releasesnode-libs-browsernpm-run-pathnumber-is-nanobject-copyobject-keysobject-visitobject.getownpropertydescriptorsobject.pickos-browserifyonceos-localep-deferp-finallyp-is-promisep-limitp-locatep-trypakoparallel-transformparse-asn1parse-passwdpascalcasepath-dirnamepath-browserifypath-is-absolutepath-existspbkdf2path-keypath-parsepifypkg-dirpostcssposix-character-classespostcss-modules-extract-importspostcss-modules-local-by-defaultpostcss-modules-scopepostcss-modules-valuesprivatepostcss-value-parserprocessprocess-nextick-argspromise-inflightpublic-encryptprrpumpquerystringpumpifypunycoderandombytesquerystring-es3randomfillreadable-streamreaddirpregenerate-unicode-propertiesregenerateregexpu-coreregenerator-transformregex-notregexp-treeregjsgenregjsparserremove-trailing-separatorrepeat-elementrequire-directoryrepeat-stringrequire-main-filenameresolve-cwdresolveresolve-dirresolve-fromresolve-urlretripemd160rimrafrun-queuesafe-buffersafe-regexschema-utilssemverserialize-javascriptsetimmediateset-blockingset-valuesha.jsshebang-commandshebang-regexsignal-exitsnapdragonsnapdragon-nodesnapdragon-utilsource-list-mapsource-mapsource-map-supportsource-map-resolvesource-map-urlsplit-stringssristatic-extendstream-eachstream-browserifystream-httpstream-shiftstring-widthstring_decoderstrip-ansistrip-eofsupports-colortapableterserterser-webpack-pluginthrough2to-arraybuffertimers-browserifyto-fast-propertiesto-object-pathto-regexto-regex-rangetslibtrim-righttypedarrayunicode-canonical-property-names-ecmascripttty-browserifyunicode-match-property-value-ecmascriptunicode-match-property-ecmascriptunicode-property-aliases-ecmascriptunion-valueunique-filenameunique-slugunset-valueupathuri-jsurixurluseutilutil-deprecateutil.promisifyv8-compile-cachevm-browserifywatchpackwebpack-sourceswhich-modulewhichwrap-ansiworker-farmwrappyxtendy18nyargsyallistyargs-parser
1.0.0

2 years ago