Giter Site home page Giter Site logo

app-setup's Introduction

App set-up

This is an empty repo to use as a set-up for an app - not a plugin or library. There aren't that many differences, but a few (like no index.js, no namespacing considerations for the object that gets exposed with a plugin, bundling as an IIFE, not a UMD module)

Fundaments

The index.html and the src/app.js is where the coding happens. app.js is the app's entry point and should get additional functions and modules via imports.

Note, there's no CSS file here. This should probably be added?

Rollup

Rollup bundles our JS. src/app.js in, dist/bundle.js and dist/bundle.min.js out. Simple. For now it considers a couple of plugins:

  • Babel (to transpile)
  • node-resolve (to find files in node_modules)
  • CommonJS (to deal with require()) and
  • Uglify (your guess...)

Check the file for more details.

Babel

Bable is transpiling our JS shlonk and does so with the most mnml of all settings ( really ). We just have to make sure it does play well with rollup - the babel plugin takes care of this.

Dependencies and Scripts

Check out the package.json for the dependencies. Nothing too special, including D3, a few key plugins and topojson.

The scripts are simply building, watching or uglifying. There's lots more one can do but this is being kept simple.

๐Ÿ•

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.