Skip to content

Commit

Permalink
fix banner
Browse files Browse the repository at this point in the history
  • Loading branch information
kianenigma committed Aug 29, 2024
1 parent 1a9cdd9 commit 96f0f17
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/templates/single.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ export default function DocsSinglePage({ data, pageContext }) {
//const pagePathNoSlash = pagePath.endsWith('/') ? pagePath.slice(0, -1) : pagePath;
const relativeFilePath = data.markdownRemark.parent.relativePath;
const location = useLocation(); // Get the current location
console.log('location.pathname: ', location.pathname);

function titleize(slug) {
let words = slug.toLowerCase().replace(/-/g, ' ');
Expand Down Expand Up @@ -105,7 +106,7 @@ export default function DocsSinglePage({ data, pageContext }) {
<h1>{title}</h1>
</header>
<main className="markdown-body">
{location.pathname !== '/polkadot-sdk' && (
{!location.pathname.includes('polkadot-sdk') && (
<div className="deprecation">
<strong>⚠️ Update Notice:</strong>
<p>
Expand Down

0 comments on commit 96f0f17

Please sign in to comment.