GithubHelp home page GithubHelp logo

isabella232 / common-18 Goto Github PK

View Code? Open in Web Editor NEW

This project forked from theintern/common

0.0 0.0 0.0 888 KB

Common functionality for Intern projects

License: Other

JavaScript 0.07% TypeScript 99.93%

common-18's Introduction

intern-common

This repository contains common library code used by Intern projects. It's essentially a subset of @dojo/core and @dojo/shim, extracted to prevent circular dependencies between Dojo and Intern.

While the implementations of Task, Evented, and the various utility functions are very similar (and in some cases the same as) their @dojo counterparts, there are a few differences. Probably the most significant is with the request module, which uses a simpler API that Dojo's request and is backed by axios.

Usage

This package exports its public interface through its base import:

import { Task, Evented, request } from '@theintern/common';

Features

The following concrete exports are provided:

  • Evented: Base class for event emitters
  • Task: Cancellable promise
  • global: Pointer to the global object (e.g., window)
  • request: Simple network request module
  • createHandle: Create a handle that can be used to cleanup resources
  • createCompositeHandle: Create an aggregate Handle
  • deepMixin: Deeply one or more objects into a target object
  • duplicate: Deep copy an object
  • partial: Create a function from a base function by binding one or more arguments of the base function to given values

Development

The development flow is standard:

  1. npm install
  2. npm run build (or npm run watch)
  3. npm test to run tests

The build process creates four webpack bundles in _build/: one is the distributable index.js, two are for unit tests (browser and Node), and one is for integration tests.

common-18's People

Contributors

jason0x43 avatar dependabot[bot] avatar edhager avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.