Skip to content

Instantly share code, notes, and snippets.

View ThariqS's full-sized avatar

Thariq Shihipar ThariqS

View GitHub Profile
import React from 'react';
export const Icon = ({ className, size=1, style, iconName }) => {
return (<i
className={`${className} gi gi-${iconName}`}
style={{...style, fontSize: `${size}em`}}
/>);
};
//
{
"type": "doc",
"content": [
{
"type": "article",
"content": [
{
"type": "paragraph",
"content": [
{
@ThariqS
ThariqS / gist:72cb138d33e7bcfd15d0440cc4bd555a
Created January 16, 2017 18:04
Prosemirror Selection Plugin
import {Decoration, DecorationSet} from "prosemirror-view";
import {Plugin} from 'prosemirror-state';
const SelectPlugin = new Plugin({
state: {
init(config, instance) {
return { deco: DecorationSet.empty };
},
apply(transaction, state, prevEditorState, editorState) {
@ThariqS
ThariqS / gist:3954686
Created October 25, 2012 18:56
operations
type
: INT_T
| FLOAT_T
| BOOL_T
| VEC_T
| IVEC_T
| BVEC_T
;
expression