Question

I've been using Fiddler for a few days now, extending CustomRules.js with my own logic. However, the file is becoming quite heavy (it's fairly heavy to begin with). I'm not very familiar with .NET or JScript, but I would like to be able to split CustomRules.js into several smaller files that I can just include into CustomRules.js. Is this possible?

I'm also finding a need to have some sort of persistent storage across requests. Is there a simple way to store values in CustomRules.js for use in later requests?

Was it helpful?

Solution

There's no direct way to split the rules file out into other files (I should probably think about adding one). What you can do is compile .NET libraries and call them from the script file, as described here: http://www.fiddler2.com/Fiddler/dev/UsingCSharp.asp

I would be interested in learning more about your Rules, as a large rules file suggests that perhaps I could bake more useful functionality directly into Fiddler.

"Persistent storage across requests"-- what type of storage? If you simply add a JavaScript global variable to the FiddlerScript, it will be maintained across requests-- this is basically how most of the Rules menu options work, for instance. If rather than "across requests" you mean "across Fiddler startups/shutdowns" then you'd have to write code to store the values to a file or the registry.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top