DEV Community

Discussion on: Make a landing page for your band in 30 minutes with gatsby-theme-musician 🎸

Collapse
 
ekafyi profile image
Eka

You can do that by shadowing the file colors.js github.com/ekafyi/gatsby-theme-mus...

  • In your site directory, create the file YOUR-SITE-DIR/src/gatsby-theme-musician/gatsby-plugin-theme-ui/colors.js and copy the content from the link above.
  • Change any value you want there.

If you're not familiar with the concept of "shadowing" in Gatsby, have a look here: gatsbyjs.org/docs/themes/shadowing/

Collapse
 
biwers profile image
Nick Cue

Thanks! And for for editing the footer ?

Thread Thread
 
ekafyi profile image
Eka

Using the same principle as above, shadow the footer file: github.com/ekafyi/gatsby-theme-mus...

Shadow the footer if you want to (for example) change/remove the copyright/credit line.

IF you just want to change your social links, shadow the config file instead: github.com/ekafyi/gatsby-theme-mus...

Thread Thread
 
biwers profile image
Nick Cue

for footer.js, where do i add it?

Thread Thread
 
biwers profile image
Nick Cue

when I put my-site/src/gatsby-theme-musician/components/footer.js

I have a error

Thread Thread
 
ekafyi profile image
Eka

The footer component has relative imports, ie. it imports these other components from the theme.

import useSiteMetadata from "../use-site-metadata"
import Social from "./social"

If you don't change those, you get errors because there's no Social component file in your site's dir. So make sure you change the import paths. You can see the example of Applying new props in gatsbyjs.org/docs/themes/shadowing... to figure out the theme import path.

Thread Thread
 
biwers profile image
Nick Cue

Thanks, but I have no idea how to solve the problem. What is the path to add?

Thread Thread
 
biwers profile image
Nick Cue

I try to add but not working

import useSiteMetadata from "gatsby-theme-musician/theme/src/"
import { Social } from "gatsby-theme-musician/theme/src/components/"

export default props =>
export default props =>

Thread Thread
 
ekafyi profile image
Eka

Try removing the theme and including the filename like in the theme.

// in the theme
import useSiteMetadata from "../use-site-metadata"
import Social from "./social"

// in your site
import useSiteMetadata from "gatsby-theme-musician/src/use-site-metadata";
import { Social } from "gatsby-theme-musician/src/components/social";
Enter fullscreen mode Exit fullscreen mode
Thread Thread
 
biwers profile image
Nick Cue

Its not working, but its ok thanks

Thread Thread
 
biwers profile image
Nick Cue

Do you know, how to change or add a favicon ?