node-fast-html-parser icon indicating copy to clipboard operation
node-fast-html-parser copied to clipboard

Plans to move away from dynamic functions?

Open jnarowski opened this issue 7 years ago • 3 comments

return pMatchFunctionCache[matcher] = new Function('el', source);

I'm not able to use this library in a serverless environment because of these dynamic functions. Any plans to refactor the code to not depend on these?

jnarowski avatar Nov 08 '18 00:11 jnarowski

Back to the time I wrote it, this was the fastest way to match nodes on a tree. Don't know if those assumptions are changed.

This can be replaced that with a closure with matching configs embedded.

ashi009 avatar Nov 08 '18 07:11 ashi009

This can be replaced that with a closure with matching configs embedded. Can you explain how to do this?.

Tahiche avatar Dec 27 '18 09:12 Tahiche

the new Function is now replaced and merged into master in this fork: https://github.com/taoqf/node-html-parser

jnarowski avatar Dec 29 '18 17:12 jnarowski