pawajs 1.3.6 → 1.3.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.js +3 -1
- package/package.json +1 -1
- package/pawaElement.js +3 -2
package/index.js
CHANGED
|
@@ -295,7 +295,9 @@ const setPrimaryAttibute = (...name) => {
|
|
|
295
295
|
primaryDirective.add(att)
|
|
296
296
|
})
|
|
297
297
|
}
|
|
298
|
-
|
|
298
|
+
|
|
299
|
+
export const getPrimaryDirectives=()=>primaryDirective
|
|
300
|
+
|
|
299
301
|
setPrimaryAttibute('if', 'else-if', 'for', 'else','switch','case','default','case','key')
|
|
300
302
|
setPawaAttributes('if', 'else-if', 'for', 'else', 'mount',
|
|
301
303
|
'unmount', 'forKey', 'state-', 'on-', 'out-','key','switch','case','default')
|
package/package.json
CHANGED
package/pawaElement.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {components,escapePawaAttribute,getPawaAttributes,getDependentAttribute} from './index.js';
|
|
1
|
+
import {components,escapePawaAttribute,getPawaAttributes,getDependentAttribute,getPrimaryDirectives } from './index.js';
|
|
2
2
|
import {splitAndAdd,replaceTemplateOperators,setPawaDevError,getEvalValues,safeEval} from './utils.js';
|
|
3
3
|
import PawaComponent from './pawaComponent.js';
|
|
4
4
|
|
|
@@ -163,8 +163,9 @@ export class PawaElement {
|
|
|
163
163
|
this._attr[attr.name]=attr.value
|
|
164
164
|
})
|
|
165
165
|
}
|
|
166
|
+
|
|
166
167
|
hasForOrIf(){
|
|
167
|
-
const primary=
|
|
168
|
+
const primary=getPrimaryDirectives()
|
|
168
169
|
let truth=false
|
|
169
170
|
primary.forEach((att)=>{
|
|
170
171
|
if(truth) return
|