diff --git a/Syntaxes/JavaScript.plist b/Syntaxes/JavaScript.plist
index ac64115..9785580 100644
--- a/Syntaxes/JavaScript.plist
+++ b/Syntaxes/JavaScript.plist
@@ -36,7 +36,7 @@
comment
match stuff like: Sound.prototype = { … } when extending an object
match
- ([a-zA-Z_?\.$]+\w*)\.(prototype)\s*=\s*
+ ([a-zA-Z_?.$][\w?.$]*)\.(prototype)\s*=\s*
name
meta.class.js
@@ -82,7 +82,7 @@
comment
match stuff like: Sound.prototype.play = function() { … }
match
- ([a-zA-Z_?\.$]+\w*)\.(prototype)\.([a-zA-Z_?\.$]+\w*)\s*=\s*(function)?\s*(\()(.*?)(\))
+ ([a-zA-Z_?.$][\w?.$]*)\.(prototype)\.([a-zA-Z_?.$][\w?.$]*)\s*=\s*(function)?\s*(\()(.*?)(\))
name
meta.function.prototype.js
@@ -108,7 +108,7 @@
comment
match stuff like: Sound.prototype.play = myfunc
match
- ([a-zA-Z_?\.\$]+\w*)\.(prototype)\.([a-zA-Z_?\.$]+\w*)\s*=\s*
+ ([a-zA-Z_?.$][\w?.$]*)\.(prototype)\.([a-zA-Z_?.$][\w?.$]*)\s*=\s*
name
meta.function.js
@@ -149,7 +149,7 @@
comment
match stuff like: Sound.play = function() { … }
match
- ([a-zA-Z_?\.\$]+\w*)\.([a-zA-Z_?\.\$]+\w*)\s*=\s*(function)\s*(\()(.*?)(\))
+ ([a-zA-Z_?.$][\w?.$]*)\.([a-zA-Z_?.$][\w?.$]*)\s*=\s*(function)\s*(\()(.*?)(\))
name
meta.function.js
@@ -185,7 +185,7 @@
comment
match stuff like: play = function() { … }
match
- ([a-zA-Z_?\$]+\w*)\s*=\s*(function)\s*(\()(.*?)(\))
+ ([a-zA-Z_?$][\w?$]*)\s*=\s*(function)\s*(\()(.*?)(\))
name
meta.function.js
@@ -257,7 +257,7 @@
comment
match stuff like: foobar: function() { … }
match
- \b([a-zA-Z_?\.$]+\w*)\s*:\s*\b(function)?\s*(\()(.*?)(\))
+ \b([a-zA-Z_?.$][\w?.$]*)\s*:\s*\b(function)?\s*(\()(.*?)(\))
name
meta.function.json.js
@@ -347,7 +347,7 @@
match
- (new)\s+(\w+\.?\w*)
+ (new)\s+(\w+(?:\.\w*)?)
name
meta.class.instance.constructor