{"action":"created","issue":{"url":"https://api.github.com/repos/ionic-team/ionic/issues/14056","repository_url":"https://api.github.com/repos/ionic-team/ionic","labels_url":"https://api.github.com/repos/ionic-team/ionic/issues/14056/labels{/name}","comments_url":"https://api.github.com/repos/ionic-team/ionic/issues/14056/comments","events_url":"https://api.github.com/repos/ionic-team/ionic/issues/14056/events","html_url":"https://github.com/ionic-team/ionic/issues/14056","id":298977513,"node_id":"MDU6SXNzdWUyOTg5Nzc1MTM=","number":14056,"title":"Alert component: AOT compile with strictNullChecks fails","user":{"login":"peterkelly","id":1472178,"node_id":"MDQ6VXNlcjE0NzIxNzg=","avatar_url":"https://avatars0.githubusercontent.com/u/1472178?v=4","gravatar_id":"","url":"https://api.github.com/users/peterkelly","html_url":"https://github.com/peterkelly","followers_url":"https://api.github.com/users/peterkelly/followers","following_url":"https://api.github.com/users/peterkelly/following{/other_user}","gists_url":"https://api.github.com/users/peterkelly/gists{/gist_id}","starred_url":"https://api.github.com/users/peterkelly/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/peterkelly/subscriptions","organizations_url":"https://api.github.com/users/peterkelly/orgs","repos_url":"https://api.github.com/users/peterkelly/repos","events_url":"https://api.github.com/users/peterkelly/events{/privacy}","received_events_url":"https://api.github.com/users/peterkelly/received_events","type":"User","site_admin":false},"labels":[{"id":1109084545,"node_id":"MDU6TGFiZWwxMTA5MDg0NTQ1","url":"https://api.github.com/repos/ionic-team/ionic/labels/ionitron:%20v3","name":"ionitron: v3","color":"444444","default":false},{"id":835668554,"node_id":"MDU6TGFiZWw4MzU2Njg1NTQ=","url":"https://api.github.com/repos/ionic-team/ionic/labels/triage","name":"triage","color":"CA357C","default":false}],"state":"closed","locked":true,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2018-02-21T13:51:16Z","updated_at":"2018-12-03T17:16:02Z","closed_at":"2018-12-03T17:16:01Z","author_association":"NONE","body":"**Ionic version:**  (check one with \"x\")\r\n[ ] **2.x**\r\n[x] **3.x**\r\n[ ] **4.x**\r\n\r\n**I'm submitting a ...**  (check one with \"x\")\r\n[x] bug report\r\n[ ] feature request\r\n\r\n**Current behavior:**\r\n\r\nWhen compiling an application that uses `ionic-angular`, and `strictNullChecks` is enabled in `tsconfig.json`, AOT compilation of the Alert component template fails with the following error:\r\n\r\n```\r\nError at /Users/peter/myapp/node_modules/ionic-angular/components/alert/alert-component.d.ts.AlertCmp.html(1,417): Object is possibly 'undefined'.\r\nError at /Users/peter/myapp/node_modules/ionic-angular/components/alert/alert-component.d.ts.AlertCmp.html(1,1760): Object is possibly 'undefined'.\r\n```\r\n\r\n**Expected behavior:**\r\n\r\nThe app should compile with no errors.\r\n\r\nNote: I understand that building Ionic itself is not yet supported with strictNullChecks enabled, but this bug is the only one that I'm aware of which prevents applications themselves from being built using Ionic and strictNullChecks.\r\n\r\n**Steps to reproduce:**\r\n\r\n1. `ionic start myapp blank`\r\n2. `cd myapp`\r\n3. Edit `tsconfig.json` and add `\"strictNullChecks\": true,` inside `compilerOptions`\r\n4. `node_modules/.bin/ngc`\r\n\r\n\r\n**Other information:**\r\n\r\nThe compile errors come from two places in the template within `src/components/alert/alert-component.ts` where possibly-undefined properties of the component are accessed: `d.inputs` and `d.buttons`.\r\n\r\nI have prepared a patch (which we have been using in our app for several months) and will submit a pull request.\r\n\r\n**Ionic info:** (run `ionic info` from a terminal/cmd prompt and paste output below):\r\n\r\n```\r\nionic info\r\n\r\ncli packages: (/usr/local/lib/node_modules)\r\n\r\n    @ionic/cli-utils  : 1.19.1\r\n    ionic (Ionic CLI) : 3.19.1\r\n\r\nlocal packages:\r\n\r\n    @ionic/app-scripts : 3.1.8\r\n    Ionic Framework    : ionic-angular 3.9.2\r\n\r\nSystem:\r\n\r\n    Node : v8.9.4\r\n    npm  : 5.5.1 \r\n    OS   : macOS High Sierra\r\n\r\nMisc:\r\n\r\n    backend : legacy\r\n```\r\n\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/ionic-team/ionic/issues/comments/443790717","html_url":"https://github.com/ionic-team/ionic/issues/14056#issuecomment-443790717","issue_url":"https://api.github.com/repos/ionic-team/ionic/issues/14056","id":443790717,"node_id":"MDEyOklzc3VlQ29tbWVudDQ0Mzc5MDcxNw==","user":{"login":"ionitron-bot[bot]","id":35967572,"node_id":"MDM6Qm90MzU5Njc1NzI=","avatar_url":"https://avatars1.githubusercontent.com/in/8640?v=4","gravatar_id":"","url":"https://api.github.com/users/ionitron-bot%5Bbot%5D","html_url":"https://github.com/apps/ionitron-bot","followers_url":"https://api.github.com/users/ionitron-bot%5Bbot%5D/followers","following_url":"https://api.github.com/users/ionitron-bot%5Bbot%5D/following{/other_user}","gists_url":"https://api.github.com/users/ionitron-bot%5Bbot%5D/gists{/gist_id}","starred_url":"https://api.github.com/users/ionitron-bot%5Bbot%5D/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ionitron-bot%5Bbot%5D/subscriptions","organizations_url":"https://api.github.com/users/ionitron-bot%5Bbot%5D/orgs","repos_url":"https://api.github.com/users/ionitron-bot%5Bbot%5D/repos","events_url":"https://api.github.com/users/ionitron-bot%5Bbot%5D/events{/privacy}","received_events_url":"https://api.github.com/users/ionitron-bot%5Bbot%5D/received_events","type":"Bot","site_admin":false},"created_at":"2018-12-03T17:15:57Z","updated_at":"2018-12-03T17:15:57Z","author_association":"NONE","body":"Thanks for the issue! We have moved the source code and issues for Ionic 3 into a separate repository. I am moving this issue to the repository for Ionic 3. Please track this issue over there.\n\nThank you for using Ionic!\n"}}
{"actor":{"display_login":"ionitron-bot"}}