From cf37697920019c44245ba3e5b69fed68c8c3fff4 Mon Sep 17 00:00:00 2001 From: Sachin George Thomas Date: Wed, 2 Nov 2016 20:22:14 +0530 Subject: [PATCH] node: open module-specific node documentation (#5572) --- plugins/node/node.plugin.zsh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/plugins/node/node.plugin.zsh b/plugins/node/node.plugin.zsh index 2463815ac..e2f18a032 100644 --- a/plugins/node/node.plugin.zsh +++ b/plugins/node/node.plugin.zsh @@ -1,5 +1,6 @@ # Open the node api for your current version to the optional section. # TODO: Make the section part easier to use. function node-docs { - open_command "http://nodejs.org/docs/$(node --version)/api/all.html#all_$1" + local section=${1:-all} + open_command "http://nodejs.org/docs/$(node --version)/api/$section.html" }