GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - CommitChange/browserify-crawl: Recursively crawl and scan directories, browserifying/watchifying multiple main files into an output directory

This repository was archived by the owner on Feb 14, 2019. It is now read-only.
BranchesTags
Open more actions menu
 
 

Latest commit

 

History

13 Commits
13 Commits

Folders and files

NameName
Last commit message
Last commit date
test
test
 
 
.babelrc
.babelrc
 
 
.eslintrc.js
.eslintrc.js
 
 
.gitignore
.gitignore
 
 
README.md
README.md
 
 
index.js
index.js
 
 
package.json
package.json
 
 

Repository files navigation

Deprecated: we use webpack now

browserify-crawl

This library is our "ideal build script" wrapped up into a module. It supports all of the following:

  • Crawls a tree of directories, finds all your main-files
  • Bundles them with Browserify using any transforms/plugins (uses errorify)
  • Creates an external source map with exorcist
  • Can optionally uglify the result (+ sourcemap)
  • Can optionally gzip the result
  • Can optionally use watchify to hang and watch for changes on any file

There is a PostCSS analog here: postcss-crawl.

crawl(options, browserifyOptions)

The options object can have these properties:

  • input: path of the input directory containing all your mainfiles (which may be in nested directories). Required.
  • output: path of your output directory, typically public/js, dist, etc. Required.
  • indexName: name of the main-file(s) that you want to get bundle. Defaults to page.js
  • log: Boolean whether to print log messages. Defaults to true
  • watch: Boolean whether to use watchify and watch for changes to files. Defaults to false
  • sourceMapUrl: Url prefix that will be used to access sourcemaps. Defaults to the output path
  • uglify: Whether to uglify your code after browserifying it. Defaults to false
  • gzip: Whether to gzip your code (will save to output/filename.js.gz). Defaults to false.

The second parameter, browserifyOptions, takes the options from the browserify api, such as transform.

const crawl = require('browserify-crawl')

const browserifyOptions = {
  transform: 'es2040'
}

const crawlOptions = {
  input: 'source/js'
, output: 'dist/js'
, gzip: true
, uglify: true
, watch: false
, sourceMapUrl: '/js'
}

crawl(crawlOptions, browserifyOptions)

About

Recursively crawl and scan directories, browserifying/watchifying multiple main files into an output directory

Resources

Readme
Activity
Custom properties

Stars

0 stars

Watchers

1 watching

Forks

0 forks
Report repository

Releases

Packages

Contributors

Languages

You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.