UNPKG
ineed
Version:
latest (1.1.0)
1.1.0
1.0.4
1.0.3
1.0.2
1.0.1
Web scraping and HTML-reprocessing. The easy way.
inikulin.github.io/ineed/
inikulin/ineed
ineed
/
lib
/
plugins
/
reprocessing
/
js_code.js
17 lines
(13 loc)
•
321 B
JavaScript
View Raw
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
module.exports = { name:
'jsCode'
, extends:
'reprocess'
,
init
: function (ctx, replacer) {
this
.ctx = ctx;
this
.replacer = replacer; }, onText: function (text) {
if
(
this
.ctx.leadingStartTag ===
'script'
) text =
this
.replacer(text);
return
text; } };