babel-plugin-trace-execution
babel-plugin-trace-execution copied to clipboard
How to use babel-plugin-trace-execution ?
I want to use babel-plugin-trace-execution on a reactjs application.
How to configure it ?
Thanks
It's good it it's now working for me
This is example repo on it https://github.com/ColCh/babel-plugin-trace-execution-demo
Works after this patch applies (within node modules)
diff --git 1/./index.js 2/./index.js.bak
index 0c1776f..bcd5bb6 100644
--- 1/./index.js
+++ 2/./index.js.bak
@@ -135,15 +135,15 @@ exports.default = function (_ref) {
* Append trace call() AFTER assignment expressions. Highlight contains
* entire expression. Bindings include new values.
*/
- // AssignmentExpression: function AssignmentExpression(path) {
- // var _path$node2 = path.node,
- // start = _path$node2.start,
- // end = _path$node2.end;
-
- // path.insertAfter(createTraceCall(_extends({
- // bindings: getBindingsForScope(path.scope, this.bindings)
- // }, getOffsettedRange(start, end, this.fnOffset))));
- // },
+ AssignmentExpression: function AssignmentExpression(path) {
+ var _path$node2 = path.node,
+ start = _path$node2.start,
+ end = _path$node2.end;
+
+ path.insertAfter(createTraceCall(_extends({
+ bindings: getBindingsForScope(path.scope, this.bindings)
+ }, getOffsettedRange(start, end, this.fnOffset))));
+ },
/**