bahmutov / bahmutov/node-hook

Cannot read property '.js' of undefined

Open
#1 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
66
Forks
7
PR merge metrics
No merged PRs in 30d

Description

Hi,

I am trying to hook a function in node module, but I got error as mentioned in the title, below is my code:

var hook = require('node-hook');
function Request(method, url) {
alert(url);
}
hook.hook('.js', Request);
require('./node_modules/module_name/index');

Is it possible on the way I am trying to archive?

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.