Skip to content

Commit

Permalink
Only run tabbing logic on docs that contain blocks
Browse files Browse the repository at this point in the history
Summary:
Builds upon #14212
Closes #14213

Differential Revision: D5149113

Pulled By: hramos

fbshipit-source-id: 99684bbb3bcae0e6061641373c6af7446729d7bd
  • Loading branch information
hramos authored and facebook-github-bot committed May 30, 2017
1 parent b302bec commit ffa76d0
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions website/src/react-native/js/scripts.js
Original file line number Diff line number Diff line change
Expand Up @@ -202,6 +202,10 @@
}

function guessPlatformAndOS() {
if (!document.querySelector('block')) {
return;
}

// If we are coming to the page with a hash in it (i.e. from a search, for example), try to get
// us as close as possible to the correct platform and dev os using the hashtag and block walk up.
var foundHash = false;
Expand Down

0 comments on commit ffa76d0

Please sign in to comment.