UML is OO based modelling language, but the notation is abstract and extendible, so you can always use stereotypes to give your own semantics to standard elements. They don't even need to be "real" classes, objects, etc. in order to be modeled in UML.
For example, you can model your C-program (C is not OO) and use a class for each .h file. The stereotype of this "new" class could be "H". This gives a concrete meaning to your model.
You can model many aspects of a system, roughly divided in structure and behavior.
Structure in JS:
In JS you can use classes to model JS-objects with their relevant attributs and functions. Events that are raised by an object can be modelled as a function with a stereotype "event".
Different UI-Elements could also be modelled as classes with corresponding stereotype (button, list, table, combo, whatever).
You can use UML dependencies to model dependencies between different JS-object (or namespaces if you prefer).
Behavior in JS
Here you can use sequence/communication diagrams to specify different scenarios. Even an activity diagram, state diagram, etc. could be handy.
I made a simple example: http://postimg.org/image/b0ae4g2jf/
This is only one possible approach. You can think of many more, depending on your concrete focus and needs.
In summary, UML can help you A LOT, in ANY SW-development, to make your code better structured, can help you to force modules instead of using a global space in JS, can help you to think about your code before you write it. Also to document it.