mirror of
https://github.com/openharmony/developtools_ace-ets2bundle.git
synced 2026-07-19 16:43:34 -04:00
wangyongfei6@huawei.com only validate stringliteral for component id Signed-off-by: yfwang6 <wangyongfei6@huawei.com> Change-Id: I84a732cb1386176710fbecf5e60c49215f651d29
This commit is contained in:
@@ -1548,7 +1548,8 @@ function updateArgumentFor$$(argument: any): ts.Expression {
|
||||
|
||||
function verifyComponentId(temp: any, node: ts.Identifier, propName: string,
|
||||
log: LogInfo[]): void {
|
||||
if (!newsupplement.isAcceleratePreview && propName === ATTRIBUTE_ID) {
|
||||
if (!newsupplement.isAcceleratePreview && propName === ATTRIBUTE_ID &&
|
||||
ts.isStringLiteral(temp.arguments[0])) {
|
||||
const id: string = temp.arguments[0].text;
|
||||
const posOfNode: ts.LineAndCharacter = transformLog.sourceFile
|
||||
.getLineAndCharacterOfPosition(getRealNodePos(node));
|
||||
|
||||
Reference in New Issue
Block a user