-
Notifications
You must be signed in to change notification settings - Fork 3
attributesParent
Bhsd edited this page Apr 18, 2026
·
2 revisions
This is an internal document. For visitors, you can now go back to the home page.
// attributes (main)
var {attributesParent} = require("../mixin/attributesParent");
var AttributesParentBase, token;
class S {
x = 0;
get attributes() {
return this.x;
}
set attributes(v) {
this.x = v;
}
}
AttributesParentBase = attributesParent()(S);
token = new AttributesParentBase();
token.childNodes = [new S()];
token.x = 1;
assert.strictEqual(token.attributes, 0);
token.attributes = 1;
assert.strictEqual(token.attributes, 1);// className (main)
var {attributesParent} = require("../mixin/attributesParent");
var AttributesParentBase, token;
class S {
x = 0;
get className() {
return this.x;
}
set className(v) {
this.x = v;
}
}
AttributesParentBase = attributesParent()(S);
token = new AttributesParentBase();
token.childNodes = [new S()];
token.x = 1;
assert.strictEqual(token.className, 0);
token.className = 1;
assert.strictEqual(token.className, 1);// classList (main)
var {attributesParent} = require("../mixin/attributesParent");
var AttributesParentBase, token;
class S {
x = 0;
get classList() {
return this.x;
}
}
AttributesParentBase = attributesParent()(S);
token = new AttributesParentBase();
token.childNodes = [new S()];
token.x = 1;
assert.strictEqual(token.classList, 0);// id (main)
var {attributesParent} = require("../mixin/attributesParent");
var AttributesParentBase, token;
class S {
x = 0;
get id() {
return this.x;
}
set id(v) {
this.x = v;
}
}
AttributesParentBase = attributesParent()(S);
token = new AttributesParentBase();
token.childNodes = [new S()];
token.x = 1;
assert.strictEqual(token.id, 0);
token.id = 1;
assert.strictEqual(token.id, 1);// hasAttr (Node.js)
var {attributesParent} = require("../mixin/attributesParent");
var AttributesParentBase, token;
class S {
x = 0;
hasAttr() {
return this.x;
}
}
AttributesParentBase = attributesParent()(S);
token = new AttributesParentBase();
token.childNodes = [new S()];
token.x = 1;
assert.strictEqual(token.hasAttr(), 0);// getAttr (Node.js)
var {attributesParent} = require("../mixin/attributesParent");
var AttributesParentBase, token;
class S {
x = 0;
getAttr() {
return this.x;
}
}
AttributesParentBase = attributesParent()(S);
token = new AttributesParentBase();
token.childNodes = [new S()];
token.x = 1;
assert.strictEqual(token.getAttr(), 0);// getAttrNames (main)
var {attributesParent} = require("../mixin/attributesParent");
var AttributesParentBase, token;
class S {
x = 0;
getAttrNames() {
return this.x;
}
}
AttributesParentBase = attributesParent()(S);
token = new AttributesParentBase();
token.childNodes = [new S()];
token.x = 1;
assert.strictEqual(token.getAttrNames(), 0);// getAttrs (main)
var {attributesParent} = require("../mixin/attributesParent");
var AttributesParentBase, token;
class S {
x = 0;
getAttrs() {
return this.x;
}
}
AttributesParentBase = attributesParent()(S);
token = new AttributesParentBase();
token.childNodes = [new S()];
token.x = 1;
assert.strictEqual(token.getAttrs(), 0);// setAttr (main)
var {attributesParent} = require("../mixin/attributesParent");
var AttributesParentBase, token;
class S {
x = 0;
setAttr(v) {
this.x = v;
}
}
AttributesParentBase = attributesParent()(S);
token = new AttributesParentBase();
token.childNodes = [new S()];
token.setAttr(1);
assert.strictEqual(token.x, 0);
assert.strictEqual(token.childNodes[0].x, 1);// removeAttr (main)
var {attributesParent} = require("../mixin/attributesParent");
var AttributesParentBase, token;
class S {
x = 0;
removeAttr() {
this.x = 1;
}
}
AttributesParentBase = attributesParent()(S);
token = new AttributesParentBase();
token.childNodes = [new S()];
token.removeAttr();
assert.strictEqual(token.x, 0);
assert.strictEqual(token.childNodes[0].x, 1);// toggleAttr (main)
var {attributesParent} = require("../mixin/attributesParent");
var AttributesParentBase, token;
class S {
x = 0;
toggleAttr() {
this.x = 1;
}
}
AttributesParentBase = attributesParent()(S);
token = new AttributesParentBase();
token.childNodes = [new S()];
token.toggleAttr();
assert.strictEqual(token.x, 0);
assert.strictEqual(token.childNodes[0].x, 1);// css (main)
var {attributesParent} = require("../mixin/attributesParent");
var AttributesParentBase, token;
class S {
x = 0;
css() {
this.x = 1;
}
}
AttributesParentBase = attributesParent()(S);
token = new AttributesParentBase();
token.childNodes = [new S()];
token.css();
assert.strictEqual(token.x, 0);
assert.strictEqual(token.childNodes[0].x, 1);对维基文本批量执行语法检查的命令行工具
轻量级的维基模板解析器
维基文本语言服务器协议实现
用于维基文本的 VS Code 扩展
A command-line tool that performs linting on Wikitext in bulk
A lightweight Wikitext template parser
An implementation of the Language Server Protocol for Wikitext
VS Code extension for Wikitext