Strange error after Compiling - Ionic 5 Angular 12

Hey Guys,

this is my first post on here. I’m about to get crazy after 2 days of experimenting and trying to find out what the *** my problem is here:

I tried to update Angular. Then i had some peer dependency issues. Tried to solve them, reinstalled a lot of packages, and then tried to compile everything. "Works like a charm, i thought. Turns out, my app compiles, but i get the following error:

Uncaught TypeError: (0 , tslib__WEBPACK_IMPORTED_MODULE_4__.__decorate) is not a function
at Module.4595 (ionic-angular.js:119)
at webpack_require (bootstrap:19)
at Module.23 (app.component.ts:8)
at webpack_require (bootstrap:19)
at Module.8835 (environment.ts:45)
at webpack_require (bootstrap:19)
at webpack_exec (main.js:2460)
at main.js:2461
at Function.webpack_require.O (chunk loaded:25)
at main.js:2462

I have no Idea at all any more what to do. Any Idea what I broke. To be honest im kind of ashamed how I ended up here.

Any help is really appreciated!

Package.json:

{
“name”: “PickAnAnt”,
“version”: “2.1.6”,
“description”: “Einfach Dinge Erledigt bekommen mit PickAnant”,
“homepage”: “https://pickanant.de”,
“scripts”: {
“ng”: “ng”,
“start”: “ng serve”,
“build”: “ng build”,
“test”: “ng test”,
“lint”: “ng lint”,
“e2e”: “ng e2e”,
“resources”: “cordova-res android && node scripts/resources.js”
},
“private”: true,
“author”: “PickAnAnt UG”,
“license”: “ISC”,
“dependencies”: {
@angular/common”: “~12.1.1”,
@angular/core”: “~12.1.1”,
@angular/fire”: “^7.1.1”,
@angular/forms”: “~12.1.1”,
@angular/google-maps”: “^12.2.12”,
@angular/platform-browser”: “~12.1.1”,
@angular/platform-browser-dynamic”: “~12.1.1”,
@angular/router”: “~12.1.1”,
@capacitor-community/fcm”: “^2.0.2”,
@capacitor-community/firebase-analytics”: “^1.0.0”,
@capacitor/app”: “1.0.6”,
@capacitor/core”: “3.3.1”,
@capacitor/haptics”: “1.1.3”,
@capacitor/keyboard”: “1.1.3”,
@capacitor/push-notifications”: “^1.0.7”,
@capacitor/status-bar”: “1.0.6”,
@googlemaps/js-api-loader”: “^1.12.8”,
@ionic/angular”: “^5.5.2”,
“firebase”: “^9.1.0”,
“rxfire”: “^6.0.0”,
“rxjs”: “~6.6.0”,
“stripe-angular”: “^1.7.0”,
“tslib”: “^2.2.0”,
“zone.js”: “~0.11.4”
},
“devDependencies”: {
@angular-devkit/build-angular”: “~12.1.1”,
@angular-eslint/builder”: “~12.0.0”,
@angular-eslint/eslint-plugin”: “~12.0.0”,
@angular-eslint/eslint-plugin-template”: “~12.0.0”,
@angular-eslint/template-parser”: “~12.0.0”,
@angular/cli”: “~12.1.1”,
@angular/compiler”: “~12.1.1”,
@angular/compiler-cli”: “~12.1.1”,
@angular/language-service”: “~12.0.1”,
@capacitor/cli”: “3.3.1”,
@ionic/angular-toolkit”: “^4.0.0”,
@types/googlemaps”: “^3.43.3”,
@types/jasmine”: “~3.6.0”,
@types/jasminewd2”: “~2.0.3”,
@types/node”: “^12.11.1”,
@typescript-eslint/eslint-plugin”: “4.16.1”,
@typescript-eslint/parser”: “4.16.1”,
“eslint”: “^7.6.0”,
“eslint-plugin-import”: “2.22.1”,
“eslint-plugin-jsdoc”: “30.7.6”,
“eslint-plugin-prefer-arrow”: “1.2.2”,
“jasmine-core”: “~3.8.0”,
“jasmine-spec-reporter”: “~5.0.0”,
“karma”: “~6.3.2”,
“karma-chrome-launcher”: “~3.1.0”,
“karma-coverage”: “~2.0.3”,
“karma-coverage-istanbul-reporter”: “~3.0.2”,
“karma-jasmine”: “~4.0.0”,
“karma-jasmine-html-reporter”: “^1.5.0”,
“protractor”: “~7.0.0”,
“ts-node”: “~8.3.0”,
“typescript”: “~4.2.4”
}
}

Please post package.json.

Sorry, I’ve added it now

Okay it is solved now, can be closed. It was something in some other config file. I have resetted all of them by creating a new Ionic app and then copying the config files to my project (tsconfig, ionic, capacitor etc).

Man, what a hassle. Thanks anyway!