fix: robust Certifications/Additional learning split
This commit is contained in:
committed by
Mrugesh Mohapatra
parent
64c969a908
commit
45e4a770a2
@ -4,7 +4,7 @@ import { Grid, Row, Col } from '@freecodecamp/react-bootstrap';
|
|||||||
import Helmet from 'react-helmet';
|
import Helmet from 'react-helmet';
|
||||||
import PropTypes from 'prop-types';
|
import PropTypes from 'prop-types';
|
||||||
import { Link } from 'gatsby';
|
import { Link } from 'gatsby';
|
||||||
import { uniq } from 'lodash';
|
import { uniq, partition } from 'lodash';
|
||||||
import { Spacer } from '../helpers';
|
import { Spacer } from '../helpers';
|
||||||
import Login from '../Header/components/Login';
|
import Login from '../Header/components/Login';
|
||||||
import CompanyLogos from './components/CompanyLogos';
|
import CompanyLogos from './components/CompanyLogos';
|
||||||
@ -39,8 +39,11 @@ const AsFeaturedSection = () => (
|
|||||||
);
|
);
|
||||||
|
|
||||||
export const Landing = ({ nodes }) => {
|
export const Landing = ({ nodes }) => {
|
||||||
const superBlocks = uniq(nodes.map(node => node.superBlock));
|
const [superBlocks, rest] = partition(
|
||||||
const interviewPrep = superBlocks.splice(-1);
|
uniq(nodes.map(node => node.superBlock)),
|
||||||
|
name => name !== 'Coding Interview Prep'
|
||||||
|
);
|
||||||
|
const interviewPrep = rest[0];
|
||||||
return (
|
return (
|
||||||
<Fragment>
|
<Fragment>
|
||||||
<Helmet>
|
<Helmet>
|
||||||
|
Reference in New Issue
Block a user