Skip to content

Instantly share code, notes, and snippets.

Avatar

Shon Diaz Wambosa

View GitHub Profile
@julianfrank
julianfrank / matterjs.vue
Created Aug 22, 2019
Vue with MAtterJS in working condition
View matterjs.vue
<template>
<div class="content">
<div id="testLabel">Testing</div>
<div id="drawhere"></div>
debug:{{JSON.stringify(debug)}}
</div>
</template>
<script>
import {
@jcreedcmu
jcreedcmu / escape.js
Created Feb 19, 2018
Escaping nodejs vm
View escape.js
////////
// The vm module lets you run a string containing javascript code 'in
// a sandbox', where you specify a context of global variables that
// exist for the duration of its execution. This works more or less
// well, and if you're in control of the code that's running, and you
// have a reasonable protocol in mind// for how it expects a certain
// context to exist and interacts with it --- like, maybe a plug-in
// API for a program, with some endpoints defined for it that do
// useful domain-specific things --- your life can go smoothly.