Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make performance of blog page hero background better #400

Closed
Closed
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
node_modules
dist
public
patches
3 changes: 2 additions & 1 deletion .prettierignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,5 @@
package.json
package-lock.json
public
plugins
plugins
patches
2 changes: 0 additions & 2 deletions gatsby-config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -211,8 +211,6 @@ const cfg: GatsbyConfig = {
resolve: 'gatsby-plugin-styled-components',
// https://styled-components.com/docs/tooling#babel-plugin
options: {
ssr: false, // We need this to prevent mismatch errors
transpileTemplateLiterals: false, // Setting to false just to be safe - think we can remove in future
displayName: true, // Good to enable when debugging - but should not be needed for production
fileName: true, // We want to use the file in the style name
preprocess: false,
Expand Down
13 changes: 13 additions & 0 deletions patches/gatsby-background-image+1.6.0.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
diff --git a/node_modules/gatsby-background-image/lib/StyleUtils.js b/node_modules/gatsby-background-image/lib/StyleUtils.js
index 1514d63..fe83fd0 100644
--- a/node_modules/gatsby-background-image/lib/StyleUtils.js
+++ b/node_modules/gatsby-background-image/lib/StyleUtils.js
@@ -25,7 +25,7 @@ var fixClassName = function fixClassName(_ref) {
var className = _ref.className,
props = (0, _objectWithoutPropertiesLoose2.default)(_ref, _excluded);
var convertedProps = (0, _HelperUtils.convertProps)(props);
- var elementExists = (0, _ClassCache.inComponentClassCache)(className);
+ var elementExists = false; //(0, _ClassCache.inComponentClassCache)(className);
var imageData = (0, _ImageUtils.getCurrentSrcData)(convertedProps);

var additionalClassname = _shortUuid.default.generate();
Loading