Hi, whenever I save a page.html file, the “addIcons” section in the page.ts file is auto-populated with the ion-icons it finds in the page.html file. The problem is, any icon that appears multiple times is added to addIcons multiple times: eg.
page.html
<ion-icon name=“sunny-outline”></ion-icon>
<ion-icon name=“sunny-outline”></ion-icon>
page.ts
addIcons({
sunnyOutline,
sunnyOutline,
})
which results in an error.
DISABLING the IONIC VSCODE EXTENSION (v1.93.3) fixes the problem, but now I lose all of its features…
Any help would be much appreciated.
my package.json:
“private”: true,
“dependencies”: {
“@angular/animations”: “^18.0.0”,
“@angular/common”: “^18.0.0”,
“@angular/compiler”: “^18.0.0”,
“@angular/core”: “^18.0.0”,
“@angular/forms”: “^18.0.0”,
“@angular/platform-browser”: “^18.0.0”,
“@angular/platform-browser-dynamic”: “^18.0.0”,
“@angular/router”: “^18.0.0”,
“@capacitor/android”: “6.0.0”,
“@capacitor/app”: “6.0.0”,
“@capacitor/core”: “6.0.0”,
“@capacitor/device”: “^6.0.0”,
“@capacitor/geolocation”: “^6.0.0”,
“@capacitor/haptics”: “6.0.0”,
“@capacitor/ios”: “6.0.0”,
“@capacitor/keyboard”: “6.0.0”,
“@capacitor/local-notifications”: “^6.0.0”,
“@capacitor/network”: “^6.0.0”,
“@capacitor/status-bar”: “6.0.0”,
“@capacitor/toast”: “^6.0.0”,
“@capgo/nativegeocoder”: “^6.0.14”,
“@ionic/angular”: “^8.0.0”,
“@ionic/storage-angular”: “^4.0.0”,
“@ngx-translate/core”: “^15.0.0”,
“@ngx-translate/http-loader”: “^8.0.0”,
“capacitor-native-settings”: “^6.0.0”,
“cordova-sqlite-storage”: “^6.1.0”,
“dayjs”: “^1.11.11”,
“ionicons”: “^7.2.1”,
“localforage-cordovasqlitedriver”: “^1.8.0”,
“rxjs”: “~7.8.0”,
“tslib”: “^2.3.0”,
“zone.js”: “~0.14.2”
},
“devDependencies”: {
“@angular-devkit/build-angular”: “^18.0.0”,
“@angular-eslint/builder”: “^18.0.0”,
“@angular-eslint/eslint-plugin”: “^18.0.0”,
“@angular-eslint/eslint-plugin-template”: “^18.0.0”,
“@angular-eslint/schematics”: “^18.0.0”,
“@angular-eslint/template-parser”: “^18.0.0”,
“@angular/cli”: “^18.0.0”,
“@angular/compiler-cli”: “^18.0.0”,
“@angular/language-service”: “^18.0.0”,
“@capacitor/cli”: “6.0.0”,
“@ionic/angular-toolkit”: “^11.0.1”,
“@types/jasmine”: “~5.1.0”,
“@typescript-eslint/eslint-plugin”: “^6.0.0”,
“@typescript-eslint/parser”: “^6.0.0”,
“eslint”: “^8.57.0”,
“eslint-plugin-import”: “^2.29.1”,
“eslint-plugin-jsdoc”: “^48.2.1”,
“eslint-plugin-prefer-arrow”: “1.2.2”,
“jasmine-core”: “~5.1.0”,
“jasmine-spec-reporter”: “~5.0.0”,
“karma”: “~6.4.0”,
“karma-chrome-launcher”: “~3.2.0”,
“karma-coverage”: “~2.2.0”,
“karma-jasmine”: “~5.1.0”,
“karma-jasmine-html-reporter”: “~2.1.0”,
“typescript”: “~5.4.0”
},