René's URL Explorer Experiment


Title: widthPixels of "tns-core-modules/platform" is incorrect inside the orientationChanged event · Issue #6314 · NativeScript/NativeScript · GitHub

Open Graph Title: widthPixels of "tns-core-modules/platform" is incorrect inside the orientationChanged event · Issue #6314 · NativeScript/NativeScript

X Title: widthPixels of "tns-core-modules/platform" is incorrect inside the orientationChanged event · Issue #6314 · NativeScript/NativeScript

Description: Did you verify this is a real problem by searching the NativeScript Forum and the other open issues in this repo? Yes Tell us about the problem Using the screen.mainScreen.widthPixels from "tns-core-modules/platform" inside the applicati...

Open Graph Description: Did you verify this is a real problem by searching the NativeScript Forum and the other open issues in this repo? Yes Tell us about the problem Using the screen.mainScreen.widthPixels from "tns-cor...

X Description: Did you verify this is a real problem by searching the NativeScript Forum and the other open issues in this repo? Yes Tell us about the problem Using the screen.mainScreen.widthPixels from "tn...

Opengraph URL: https://github.com/NativeScript/NativeScript/issues/6314

X: @github

direct link

Domain: github.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"widthPixels of \"tns-core-modules/platform\" is incorrect inside the orientationChanged event","articleBody":"### Did you verify this is a real problem by searching the [NativeScript Forum](http://forum.nativescript.org) and the [other open issues in this repo](https://github.com/NativeScript/nativescript/issues)?\r\nYes\r\n\r\n### Tell us about the problem\r\nUsing the `screen.mainScreen.widthPixels` from `\"tns-core-modules/platform\"` inside the application `orientationChanged`\r\n event returns the previous orientation's size. \r\n\r\n### Which platform(s) does your issue occur on?\r\nTested on Android\r\n\r\n### Please provide the following version numbers that your issue occurs with:\r\n- CLI: (run `tns --version` to fetch it)\r\n- Cross-platform modules: 4.2.0\r\n- Runtime(s): 4.2.0\r\n- Plugin(s): (look for the version number in the `package.json` file of your\r\nproject)\r\n```\r\n\"dependencies\": {\r\n    \"@angular/common\": \"~6.1.0\",\r\n    \"@angular/compiler\": \"~6.1.0\",\r\n    \"@angular/core\": \"~6.1.0\",\r\n    \"@angular/forms\": \"~6.1.0\",\r\n    \"@angular/http\": \"~6.1.0\",\r\n    \"@angular/platform-browser\": \"~6.1.0\",\r\n    \"@angular/platform-browser-dynamic\": \"~6.1.0\",\r\n    \"@angular/router\": \"~6.1.0\",\r\n    \"@ngrx/store\": \"4.1.1\",\r\n    \"nativescript-angular\": \"^6.0.0\",\r\n    \"nativescript-camera\": \"4.0.2\",\r\n    \"nativescript-floatingactionbutton\": \"4.1.3\",\r\n    \"nativescript-fresco\": \"4.0.0\",\r\n    \"nativescript-google-analytics\": \"0.4.4\",\r\n    \"nativescript-image-swipe\": \"3.0.0\",\r\n    \"nativescript-imagepicker\": \"6.0.3\",\r\n    \"nativescript-iqkeyboardmanager\": \"1.1.0\",\r\n    \"nativescript-orientation\": \"^2.2.0\",\r\n    \"nativescript-toasty\": \"^1.1.5\",\r\n    \"nativescript-ui-listview\": \"^3.5.11\",\r\n    \"nativescript-ui-sidedrawer\": \"^4.3.0\",\r\n    \"reflect-metadata\": \"0.1.10\",\r\n    \"rxjs\": \"~6.1.0\",\r\n    \"rxjs-compat\": \"^6.2.2\",\r\n    \"tns-core-modules\": \"^4.2.0\",\r\n    \"zone.js\": \"^0.8.26\"\r\n  },\r\n  \"devDependencies\": {\r\n    \"@angular/compiler-cli\": \"~6.1.0\",\r\n    \"@ngtools/webpack\": \"~6.1.0\",\r\n    \"nativescript-dev-typescript\": \"~0.7.2\",\r\n    \"nativescript-dev-webpack\": \"^0.15.1\",\r\n    \"tns-platform-declarations\": \"4.2.0\",\r\n    \"typescript\": \"~2.8.2\"\r\n  },\r\n```\r\n\r\n### Please tell us how to recreate the issue in as much detail as possible.\r\nAttach to the application's `orientationChangedEvent` and try to retrieve the screen's width in Pixels\r\n`import * as applicationModule from 'tns-core-modules/application';`\r\n\r\n```\r\nimport { screen } from \"tns-core-modules/platform\";\r\n...\r\nconst screeWidth = screen.mainScreen.widthPixels\r\n```\r\n\r\n### Is there code involved? If so, please share the minimal amount of code needed to recreate the problem.\r\n\r\n\r\n\r\n\r\n\r\n\u003cbountysource-plugin\u003e\r\n\r\n---\r\nWant to back this issue? **[Post a bounty on it!](https://www.bountysource.com/issues/63960575-widthpixels-of-tns-core-modules-platform-is-incorrect-inside-the-orientationchanged-event?utm_campaign=plugin\u0026utm_content=tracker%2F12908224\u0026utm_medium=issues\u0026utm_source=github)** We accept bounties via [Bountysource](https://www.bountysource.com/?utm_campaign=plugin\u0026utm_content=tracker%2F12908224\u0026utm_medium=issues\u0026utm_source=github).\r\n\u003c/bountysource-plugin\u003e","author":{"url":"https://github.com/VladimirAmiorkov","@type":"Person","name":"VladimirAmiorkov"},"datePublished":"2018-09-27T14:37:34.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":0},"url":"https://github.com/6314/NativeScript/issues/6314"}

route-pattern/_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format)
route-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:73006a56-d9bd-b1b7-2853-55253331dd50
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-idA9FC:1B9F72:14DB13:1BA823:6A5BBCBA
html-safe-noncee6fc5dc6e0b13253991ab6476637621ad22ef1c3435dba53f1d47d133b35152c
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBOUZDOjFCOUY3MjoxNERCMTM6MUJBODIzOjZBNUJCQ0JBIiwidmlzaXRvcl9pZCI6IjQwMDc1NTI1NjE2OTE5OTk0MTgiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ==
visitor-hmacc8f31de44d93cba5e300312580b6753fd3cd4b78fb60dd1e6c000eab3d150cc0
hovercard-subject-tagissue:364508819
github-keyboard-shortcutsrepository,issues,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/issues_fragments/issue_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/NativeScript/NativeScript/6314/issue_layout
twitter:imagehttps://opengraph.githubassets.com/be6705d9443dedea2af8b189d077aea8acb7722b510cfeaa5568eae6c07b1d7a/NativeScript/NativeScript/issues/6314
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/be6705d9443dedea2af8b189d077aea8acb7722b510cfeaa5568eae6c07b1d7a/NativeScript/NativeScript/issues/6314
og:image:altDid you verify this is a real problem by searching the NativeScript Forum and the other open issues in this repo? Yes Tell us about the problem Using the screen.mainScreen.widthPixels from "tns-cor...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernameVladimirAmiorkov
hostnamegithub.com
expected-hostnamegithub.com
None5290d7e14309ad1e76106a9c4237bd1041517e83ea182c8ab756752cb0c6940b
turbo-cache-controlno-preview
go-importgithub.com/NativeScript/NativeScript git https://github.com/NativeScript/NativeScript.git
octolytics-dimension-user_id7392261
octolytics-dimension-user_loginNativeScript
octolytics-dimension-repository_id31492490
octolytics-dimension-repository_nwoNativeScript/NativeScript
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id31492490
octolytics-dimension-repository_network_root_nwoNativeScript/NativeScript
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release9c975978430e9ad293956f2bbdaf153b1bd84a99
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/NativeScript/NativeScript/issues/6314#start-of-content
https://github.com/
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2FNativeScript%2FNativeScript%2Fissues%2F6314
GitHub CopilotWrite better code with AIhttps://github.com/features/copilot
GitHub Copilot appDirect agents from issue to mergehttps://github.com/features/ai/github-app
MCP RegistryNewIntegrate external toolshttps://github.com/mcp
ActionsAutomate any workflowhttps://github.com/features/actions
CodespacesInstant dev environmentshttps://github.com/features/codespaces
IssuesPlan and track workhttps://github.com/features/issues
Code ReviewManage code changeshttps://github.com/features/code-review
GitHub Advanced SecurityFind and fix vulnerabilitieshttps://github.com/security/advanced-security
Code securitySecure your code as you buildhttps://github.com/security/advanced-security/code-security
Secret protectionStop leaks before they starthttps://github.com/security/advanced-security/secret-protection
Why GitHubhttps://github.com/why-github
Documentationhttps://docs.github.com
Bloghttps://github.blog
Changeloghttps://github.blog/changelog
Marketplacehttps://github.com/marketplace
View all featureshttps://github.com/features
Enterpriseshttps://github.com/enterprise
Small and medium teamshttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
App Modernizationhttps://github.com/solutions/use-case/app-modernization
DevSecOpshttps://github.com/solutions/use-case/devsecops
DevOpshttps://github.com/solutions/use-case/devops
CI/CDhttps://github.com/solutions/use-case/ci-cd
View all use caseshttps://github.com/solutions/use-case
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
View all industrieshttps://github.com/solutions/industry
View all solutionshttps://github.com/solutions
AIhttps://github.com/resources/articles?topic=ai
Software Developmenthttps://github.com/resources/articles?topic=software-development
DevOpshttps://github.com/resources/articles?topic=devops
Securityhttps://github.com/resources/articles?topic=security
View all topicshttps://github.com/resources/articles
Customer storieshttps://github.com/customer-stories
Events & webinarshttps://github.com/resources/events
Ebooks & reportshttps://github.com/resources/whitepapers
Business insightshttps://github.com/solutions/executive-insights
GitHub Skillshttps://skills.github.com
Documentationhttps://docs.github.com
Customer supporthttps://support.github.com
Community forumhttps://github.com/orgs/community/discussions
Trust centerhttps://github.com/trust-center
Partnershttps://github.com/partners
View all resourceshttps://github.com/resources
GitHub SponsorsFund open source developershttps://github.com/open-source/sponsors
Security Labhttps://securitylab.github.com
Maintainer Communityhttps://maintainers.github.com
Acceleratorhttps://github.com/open-source/accelerator
GitHub Starshttps://stars.github.com
Archive Programhttps://archiveprogram.github.com
Topicshttps://github.com/topics
Trendinghttps://github.com/trending
Collectionshttps://github.com/collections
Enterprise platformAI-powered developer platformhttps://github.com/enterprise
GitHub Advanced SecurityEnterprise-grade security featureshttps://github.com/security/advanced-security
Copilot for BusinessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Pricinghttps://github.com/pricing
Search syntax tipshttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
documentationhttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2FNativeScript%2FNativeScript%2Fissues%2F6314
Sign up https://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fissues_fragments%2Fissue_layout&source=header-repo&source_repo=NativeScript%2FNativeScript
Reloadhttps://github.com/NativeScript/NativeScript/issues/6314
Reloadhttps://github.com/NativeScript/NativeScript/issues/6314
Reloadhttps://github.com/NativeScript/NativeScript/issues/6314
Please reload this pagehttps://github.com/NativeScript/NativeScript/issues/6314
NativeScript https://github.com/NativeScript
NativeScripthttps://github.com/NativeScript/NativeScript
Please reload this pagehttps://github.com/NativeScript/NativeScript/issues/6314
Notifications https://github.com/login?return_to=%2FNativeScript%2FNativeScript
Fork 1.7k https://github.com/login?return_to=%2FNativeScript%2FNativeScript
Star 25.6k https://github.com/login?return_to=%2FNativeScript%2FNativeScript
Code https://github.com/NativeScript/NativeScript
Issues 771 https://github.com/NativeScript/NativeScript/issues
Pull requests 67 https://github.com/NativeScript/NativeScript/pulls
Discussions https://github.com/NativeScript/NativeScript/discussions
Actions https://github.com/NativeScript/NativeScript/actions
Projects https://github.com/NativeScript/NativeScript/projects
Wiki https://github.com/NativeScript/NativeScript/wiki
Security and quality 0 https://github.com/NativeScript/NativeScript/security
Insights https://github.com/NativeScript/NativeScript/pulse
Code https://github.com/NativeScript/NativeScript
Issues https://github.com/NativeScript/NativeScript/issues
Pull requests https://github.com/NativeScript/NativeScript/pulls
Discussions https://github.com/NativeScript/NativeScript/discussions
Actions https://github.com/NativeScript/NativeScript/actions
Projects https://github.com/NativeScript/NativeScript/projects
Wiki https://github.com/NativeScript/NativeScript/wiki
Security and quality https://github.com/NativeScript/NativeScript/security
Insights https://github.com/NativeScript/NativeScript/pulse
#10530https://github.com/NativeScript/NativeScript/pull/10530
widthPixels of "tns-core-modules/platform" is incorrect inside the orientationChanged eventhttps://github.com/NativeScript/NativeScript/issues/6314#top
#10530https://github.com/NativeScript/NativeScript/pull/10530
backloghttps://github.com/NativeScript/NativeScript/issues?q=state%3Aopen%20label%3A%22backlog%22
bughttps://github.com/NativeScript/NativeScript/issues?q=state%3Aopen%20label%3A%22bug%22
severity: lowhttps://github.com/NativeScript/NativeScript/issues?q=state%3Aopen%20label%3A%22severity%3A%20low%22
https://github.com/VladimirAmiorkov
VladimirAmiorkovhttps://github.com/VladimirAmiorkov
on Sep 27, 2018https://github.com/NativeScript/NativeScript/issues/6314#issue-364508819
NativeScript Forumhttp://forum.nativescript.org
other open issues in this repohttps://github.com/NativeScript/nativescript/issues
Post a bounty on it!https://www.bountysource.com/issues/63960575-widthpixels-of-tns-core-modules-platform-is-incorrect-inside-the-orientationchanged-event?utm_campaign=plugin&utm_content=tracker%2F12908224&utm_medium=issues&utm_source=github
Bountysourcehttps://www.bountysource.com/?utm_campaign=plugin&utm_content=tracker%2F12908224&utm_medium=issues&utm_source=github
backloghttps://github.com/NativeScript/NativeScript/issues?q=state%3Aopen%20label%3A%22backlog%22
bughttps://github.com/NativeScript/NativeScript/issues?q=state%3Aopen%20label%3A%22bug%22
severity: lowhttps://github.com/NativeScript/NativeScript/issues?q=state%3Aopen%20label%3A%22severity%3A%20low%22
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.