New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

appdir

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

appdir

install a link to your app/ dir in node_modules

  • 1.0.1
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
2
decreased by-60%
Maintainers
1
Weekly downloads
 
Created
Source

appdir

why?

You want to require application-specific code like a pro, but relative paths are messy and messing with $NODE_PATH is not recommended

how.

This module installs a symbolic link to your app subdirectory from node_modules:

app/
  views/
  models/
  whatever/
node_modules/
  app -> ../app
  ...

Now you can require('app/views/some-view') from anywhere in your app. No more relative paths or $NODE_PATH trickery.

what.

Before:

// relative paths all over your app's require calls, yuk.
var SomeView = require('../../views/some-view')

After:

// now you can use require('app/...') from anywhere in your app
var SomeView = require('app/views/some-view.js')

install

npm install --save appdir

Keywords

FAQs

Package last updated on 13 Feb 2015

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