Skip to content

Instantly share code, notes, and snippets.

View AmyAmy's full-sized avatar
💜
💜

Amy AmyAmy

💜
💜
View GitHub Profile
@AmyAmy
AmyAmy / traits.js
Last active February 11, 2024 23:59 — forked from lukescott/gist:36453a75c39c539f5c7d
Traits in ES6 now
import babelHelpers from "babelHelpers";
/* eslint no-underscore-dangle: ["error", { "allow": ["__traits__"] }] */
/**
* @author based on https://gist.github.com/lukescott/36453a75c39c539f5c7d
* @example
* var Trait1 = {
* method1() {}
* };