npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

grunt-laxar

v1.2.0-alpha.0

Published

Grunt tasks for LaxarJS

Downloads

20

Readme

grunt-laxar Build Status

Grunt tasks for LaxarJS

grunt-laxar provides a couple of custom Grunt tasks for LaxarJS applications, plus matching default configuration for several tasks from the Grunt community.

$ grunt laxar-test laxar-build laxar-dist laxar-develop
        └─1──────┘ └─2───────┘ └─3──────┘ └─4─────────┘

  1) run widget tests
  2) generate required application artifacts, bring your own server
  3) generate an optimized version for production (may take a bit longer)
  4) do a build, then run a development server with live-reload of changes

Getting Started

This plugin requires Grunt ~0.4.4. In case you have not used Grunt before, be sure to have a look at its Getting Started guide.

To use this plugin, you first need to install it using npm:

$ npm install grunt-laxar

After that, load its tasks from your Gruntfile:

grunt.loadNpmTasks( 'grunt-laxar' );

Main Tasks

These are the bread-and-butter tasks for developing and optimizing your LaxarJS application. Usually, the only task that you will have to configure manually is laxar-configure.

These tasks form the public API for grunt-laxar, and any change in their configuration or end-result is subject to the semantic versioning of this package.

laxar-configure

Configures all flow-based tasks and their building blocks. This is the only task that requires manual configuration (more).

laxar-build

Generates all artifacts that are needed to develop your application on an existing web server (more).

laxar-develop

Generates dependencies and resource listings required by the LaxarJS runtime, and starts a development server with live reloading (more).

laxar-dist

Prepares your application for production (more).

laxar-test

Runs the spec tests of all widgets that are a direct part of the application (more).

laxar-test-widget

Runs the spec test of an individual widget (more).

laxar-info

Obtain information about the artifacts in your application (more).

laxar-dox

Create API documentation in Markdown format (more).

Internal Building-Block Tasks

These tasks are used under the hood by the main tasks listed above.

Usually you do not need to know the details on these tasks, but sometimes you can save a few seconds by only running the sub-tasks you need, instead of the whole toolchain. The APIs of these tasks and their intermediate output is considered internal, so that behavior may change in incompatible ways between minor versions of grunt-laxar.

All of these tasks are multitasks that must be configured once for each set of flows that they may handle. Thus, If your Gruntfile contains the laxar-configure settings given above, you would (re)create the artifacts model for the main flow by executing:

grunt laxar-configure laxar-artifacts:main

The easiest way to generate the required configuration is by running laxar-configure before launching any of these tasks. The main tasks listed above do that for you out of the box.

laxar-build-flow

For a given flow target, generates all artifacts that are needed to run that flow in the browser during development (more).

laxar-artifacts

For a given flow target, collects all reachable artifacts and produce an artifacts model in JSON format (more).

laxar-resources

For a given flow target, determines static assets (JSON, CSS, HTML) from the artifacts model in order to produce a resources listing in JSON format (more).

laxar-dependencies

For a given flow target, generates an AMD module that references all direct dependencies (more).

laxar-merge-require-config

For a given flow target, collects and merges all require_config.js files found in widgets and controls (more).

laxar-configure-watch

For a given flow target, generates configuration for watch targets (more).

laxar-dist-flow

For a given flow target, produces optimized assets (CSS, JavaScript) (more).

laxar-dist-js

For a given flow target, uses r.js to create an optimized JavaScript bundle (more).

laxar-dist-css

For a given flow target, uses clean-css (via cssmin) in order to create a single, optimized CSS file for each theme (more).

laxar-test-flow

For a given flow target, run all widget tests (more).

laxar-test-configure-flow

Prepares test-configuration for all widgets of the given flow (more).

laxar-test-widget-internal

Runs pre-configured widget tests (prepared by laxar-test-configure-flow or by laxar-test-widget) (more).

Deprecated Tasks

These tasks were originally available for LaxarJS v0.x and have similar objectives to the tasks listed above. Yhese tasks are kept for compatibility only, because they shipped with LaxarJS v1.0. It is recommended to instead use the tasks listed above, which are flow-aware and much less likely to cause CPU problems due to rampant watchers.

Third-Party Tasks

These tasks are automatically configured by grunt-laxar to work with a LaxarJS application. Starting with grunt-laxar v1.1.0, it is recommended not to use these tasks directly but to use the main tasks above. If using these tasks directly, try not to rely on the current pre-configuration performed by grunt-laxar. In the future, configuration for these tasks may be scoped to affect only specific named targets defined by grunt-laxar This way, configuration will not influence any (alias) tasks defined by yourself.