The "I'm feeling lucky" URL shortener.
Function.apply, you might Google "apply site:developer.mozilla.org" and click the first result.
mdn.io does that for you, and can be configured to search any domain.
Use it in comments when explaining concepts
// Make sure add() takes a single argument (see http://mdn.io/Function.length) expect(queue.add.length).to.equal(1);
friend: dude, is it
apply()that takes an array?
Type directly in the address bar as a shortcut to search the MDN
How does it work?
mdn.io uses Google's "I'm feeling lucky" functionality to redirect you to the first search result.
Note that, because this is a search, the page you're redirected to may change in the future. However, you can rest assured that you'll always be redirected to the page that Google finds most relevant.
Searching other domains
mdn.io can be used to search any domain. See the configuration section and fire up your own instance.
npm install # Install dependencies. npm start # Start server locally.
Configure mdn.io with the following environment variables:
||The port to run the server on.||
||The search service URL to use.||
||The domain to search.||
||The fallback URL for empty queries.||
Alternative service URLs:
- Google -
- Bing -
http://www.bing.com/search?q=%s(Bing does not have an "I'm Feeling Lucky" equivalent, you'll be redirected to the search result page instead)
Example: Reddit URL shortener
SEARCH_DOMAIN="reddit.com" FALLBACK_URL="http://reddit.com" PORT=8080 npm start
npm run deploy