Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

bugcore

Package Overview
Dependencies
Maintainers
1
Versions
60
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

bugcore

bugcore is a JavaScript library that provides a foundational architecture for object oriented JS

  • 0.1.1
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
62
Maintainers
1
Weekly downloads
 
Created
Source

bugcore

bugcore is a JavaScript library that provides a foundational architecture for object oriented JS. It is designed to work both within node js as well as directly in the browser.

bugcore provides a basic class model based on John Resig's simple JavaScript inheritance. In addition the library provides many basic data models and utility classes for common object oriented patterns.

Quick Examples

Creation of a new class

var SomeClass = Class.extend(Obj, {});

Creation of a new class with a constructor

var SomeClass = Class.extend(Obj, {
    _constructor: function() {}
});

The library is extremely robust and makes up the foundation of our architecture for airbug so check out the docs for an overview of the full power of what the code has to offer. If the library is missing something you need, please let us know!

Download

The source is available for download from GitHub Alternatively, you can install using Node Package Manager (npm):

npm install bugcore

In the Browser

Usage:

<script type="text/javascript" src="bugcore.js"></script>
<script type="text/javascript">

    var map = new bugcore.Map();

</script>

Documentation

Class system

  • Class
  • Obj

Data Models

Class

Core static class used to build other classes.

Class.extend

Method

  • @static
  • @param {new:Base} _class
  • @param {Object} declaration
  • @return {new:Base}

Parameters

  • _class {new:Base} - The class to extend
  • declaration {Object} - An object that declares the methods of the new class

Returns

  • {new:Base} - the newly created class

Examples

var BaseBall = Class.extend(Ball, {

    _constructor: function(diameter) {
        this.diameter = diameter;
    }

    throwBall: function() {

    }
});

FAQs

Package last updated on 01 Apr 2014

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc