diff --git a/packages/react-core/src/components/Nav/examples/Nav.md b/packages/react-core/src/components/Nav/examples/Nav.md
index c00ac933d5c..f9ae73ae400 100644
--- a/packages/react-core/src/components/Nav/examples/Nav.md
+++ b/packages/react-core/src/components/Nav/examples/Nav.md
@@ -12,667 +12,51 @@ import './nav.css';
### Default
-```js
-import React from 'react';
-import { Nav, NavExpandable, NavItem, NavItemSeparator, NavList, NavGroup } from '@patternfly/react-core';
-
-class NavDefaultList extends React.Component {
- constructor(props) {
- super(props);
- this.state = {
- activeItem: 0
- };
- this.onSelect = result => {
- this.setState({
- activeItem: result.itemId
- });
- };
- }
-
- render() {
- const { activeItem } = this.state;
- return (
-
- );
- }
-}
+```ts file="./NavDefault.tsx"
```
### Grouped
-Note: to keep nav groups accessible an `aria-label` should be supplied if the `title` prop is not passed.
-
-```js
-import React from 'react';
-import { Nav, NavExpandable, NavItem, NavItemSeparator, NavList, NavGroup } from '@patternfly/react-core';
-
-class NavGroupedList extends React.Component {
- constructor(props) {
- super(props);
- this.state = {
- activeItem: 'grp-1_itm-1'
- };
- this.onSelect = result => {
- this.setState({
- activeItem: result.itemId
- });
- };
- }
+The following example shows two navigation groups, each with a `title` prop passed into the nav group component. To keep nav groups accessible an `aria-label` must be passed in if the `title` prop is not passed in.
- render() {
- const { activeItem } = this.state;
- return (
-
- );
- }
-}
+```ts file="./NavGrouped.tsx"
```
### Expandable
-```js
-import React from 'react';
-import { Nav, NavExpandable, NavItem, NavItemSeparator, NavList, NavGroup } from '@patternfly/react-core';
-
-class NavExpandableList extends React.Component {
- constructor(props) {
- super(props);
- this.state = {
- activeGroup: 'grp-1',
- activeItem: 'grp-1_itm-1'
- };
- this.onSelect = result => {
- this.setState({
- activeGroup: result.groupId,
- activeItem: result.itemId
- });
- };
- this.onToggle = result => {
- // eslint-disable-next-line no-console
- console.log(`Group ${result.groupId} expanded? ${result.isExpanded}`);
- };
- this.handleItemOnclick = (event, itemId, groupId) => {
- // eslint-disable-next-line no-console
- console.log(`my own click handler on ${itemId}`);
- };
- }
-
- render() {
- const { activeGroup, activeItem } = this.state;
- return (
-
- );
- }
-}
-```
-
-### Expandable (w/subnavigation titles)
-
-```js
-import React from 'react';
-import { Nav, NavExpandable, NavItem, NavItemSeparator, NavList, NavGroup } from '@patternfly/react-core';
-
-class NavExpandableTitlesList extends React.Component {
- constructor(props) {
- super(props);
- this.state = {
- activeGroup: 'grp-1',
- activeItem: 'grp-1_itm-1'
- };
- this.onSelect = result => {
- this.setState({
- activeGroup: result.groupId,
- activeItem: result.itemId
- });
- };
- }
-
- render() {
- const { activeGroup, activeItem } = this.state;
- return (
-
- );
- }
-}
+```ts file="./NavExpandable.tsx"
```
### Expandable third level
-```js
-import React from 'react';
-import { Nav, NavExpandable, NavItem, NavList } from '@patternfly/react-core';
-
-NavExpandableThirdLevelList = () => {
- const [activeGroup, setActiveGroup] = React.useState('grp-1');
- const [activeItem, setActiveItem] = React.useState('grp-1_itm-1');
-
- onSelect = result => {
- setActiveGroup(result.groupId);
- setActiveItem(result.itemId);
- };
-
- onToggle = result => {
- // eslint-disable-next-line no-console
- console.log(`Group ${result.groupId} expanded? ${result.isExpanded}`);
- };
-
- return (
-
- );
-};
+```ts file="./NavExpandableThirdLevel.tsx"
```
### Mixed
-```js
-import React from 'react';
-import { Nav, NavExpandable, NavItem, NavItemSeparator, NavList, NavGroup } from '@patternfly/react-core';
-
-class NavMixedList extends React.Component {
- constructor(props) {
- super(props);
- this.state = {
- activeGroup: '',
- activeItem: 'itm-1'
- };
- this.onSelect = result => {
- this.setState({
- activeGroup: result.groupId,
- activeItem: result.itemId
- });
- };
- }
-
- render() {
- const { activeGroup, activeItem } = this.state;
- return (
-
- );
- }
-}
+```ts file="./NavMixed.tsx"
```
### Horizontal (only in PageHeader)
-```js
-import React from 'react';
-import { Nav, NavExpandable, NavItem, NavItemSeparator, NavList, NavGroup, PageHeader } from '@patternfly/react-core';
-
-class NavHorizontalList extends React.Component {
- constructor(props) {
- super(props);
- this.state = {
- activeItem: 0
- };
- this.onSelect = result => {
- this.setState({
- activeItem: result.itemId
- });
- };
- }
-
- render() {
- const { activeItem } = this.state;
- const nav = (
-
- );
- return