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 🙏

© 2026 – Pkg Stats / Ryan Hefner

do-framework

v0.0.29

Published

simple node framework

Readme

Abstract

do-faramework is SIMPLE Node.js framework.

Features

  1. Very simple in structure, easy to custom.
  2. There are very few CALLBACK, source code is easy to see.
  3. Easy to see the working directory of programmers and designers.

Installation

Before installing, download and install Node.js and npm.

npm -g install do-framework

Create Project

Project directory can be created with the following command.

do-framework [project name]

Example(http server)

①. create file "/back/http/controller.js" and input the following code.

【controller.js】

var Do = module.parent.exports.Do;

exports['action'] = function* (req, res) {
    return Do.output.view('controller/action', { title: 'TEST TITLE' });
}

②. create file "/front/view/controller/action.ejs" and input the following code.

【action.ejs】

<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <title><%= title %></title>
</head>
<body>
test
</body>
</html>

③. start http server in root of project directory

npm run start

④. access http or https ://host:port/controller/action

you can see sample page!

Example(socket.io)

①. create file "/back/http/controllerio.js" and input the following code.

【controllerio.js】

var Do = module.parent.exports.Do;

exports['actionio'] = function* (req, res) {
    return Do.output.view('controller/viewIo', { title: 'TEST TITLE2' });
}

②. create file "/front/view/controller/action.ejs" and input the following code.

【viewio.ejs】

<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <title><%= title %></title>
</head>
<body>
    <script src="/js/jquery.min.js"></script>
    <script src="/socket.io/socket.io.js"></script>
    <script>
        var socket = io.connect('/test');
        socket.emit('send', "test");
        socket.on('send', function (data) {
            alert(data);
        });
    </script>
</body>
</html>

③. create file "/back/io/test.js" and input the following code.

var Do = module.parent.exports.Do;
exports['send'] = function* (socket, data) {
    socket.emit('send', 'sended!');
}

④. start http server in root of project directory

npm run start

⑤. access http or https ://host:port/controllerio/actionio

you can see "sended!" alert!

Example(batch)

①. create file "/back/batch/test.js" and input the following code.

【test.js】

var Do = module.parent.exports.Do;

exports['go'] = function* (args) {
    console.log("batch done!")
    return "OK";
}

②. start batch in root of project directory

npm run batch test/go

you can see "batch done!" text in console

Boot option

see package.json

:
  "scripts": {
    "start": "NODE_ENV=ENV1 NODE_BATCH=0 node app.js",
    "batch": "NODE_ENV=ENV1 NODE_BATCH=1 node app.js"
  },
:

NODE_ENV

When boot node, load config file in config/【NODE_ENV】 directory e.g. LOADED config/ENV1/Do.js LOADED config/ENV1/http.js LOADED config/ENV1/mongo.js LOADED config/ENV1/mysql.js LOADED config/ENV1/redis.js

NODE_BATCH

execute batch program or not.