namirasoft-core
Advanced tools
Comparing version 1.3.44 to 1.3.45
@@ -41,4 +41,4 @@ export declare class NamingConvention { | ||
getWords(name: string): string[]; | ||
convertByWords(words: string[], to: NamingConvention): string; | ||
convertByWords(words: string[]): string; | ||
convert(name: string, to: NamingConvention): string; | ||
} |
@@ -16,10 +16,10 @@ "use strict"; | ||
} | ||
convertByWords(words, to) { | ||
convertByWords(words) { | ||
for (let i = 0; i < words.length; i++) | ||
words[i] = to.formatter(words[i], i); | ||
return words.join(to.delimiter); | ||
words[i] = this.formatter(words[i], i); | ||
return words.join(this.delimiter); | ||
} | ||
convert(name, to) { | ||
let words = this.getWords(name); | ||
return this.convertByWords(words, to); | ||
return to.convertByWords(words); | ||
} | ||
@@ -26,0 +26,0 @@ } |
@@ -11,3 +11,3 @@ { | ||
"private": false, | ||
"version": "1.3.44", | ||
"version": "1.3.45", | ||
"author": "Amir Abolhasani", | ||
@@ -14,0 +14,0 @@ "license": "MIT", |
@@ -91,7 +91,7 @@ export class NamingConvention | ||
} | ||
convertByWords(words: string[], to: NamingConvention) | ||
convertByWords(words: string[]) | ||
{ | ||
for (let i = 0; i < words.length; i++) | ||
words[i] = to.formatter(words[i], i); | ||
return words.join(to.delimiter); | ||
words[i] = this.formatter(words[i], i); | ||
return words.join(this.delimiter); | ||
} | ||
@@ -101,4 +101,4 @@ convert(name: string, to: NamingConvention) | ||
let words = this.getWords(name); | ||
return this.convertByWords(words, to); | ||
return to.convertByWords(words); | ||
} | ||
} |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
350551