Skip to main content
Module

x/mixwithts/mod.ts>apply

TypeScript compatible version of Justin Fagani's mixin library for ES6
Latest
variable apply
import { apply } from "https://deno.land/x/mixwithts@1.1.2/mod.ts";

Applies mixin to superclass.

apply stores a reference from the mixin application to the unwrapped mixin to make isApplicationOf and hasMixin work.

This function is useful for mixin wrappers that want to automatically enable hasMixin support.

type

<C extends Constructable, T>(superclass: C, mixin: mixin<C, T>) => T