Comments (4)
Same Problem here.
In our case it is a Custom AcfBlock with an image in it. All following blocks are rendered inside the gatsby-image-wrapper
Edit: oh we use gatsby-wordpress-experimental-inline-images
by the way.
from gatsby-wordpress-inline-images.
Hi @Jehu,
This is far from a permanent solution but it works for me for building my articles at the moment.
I narrowed the issue down to a missing closing div for each gatsby-image-wrapper
If you are using dangerouslySetInnerHTML
for your post content you can create function to correct the markup:
parsePostContents = (contents) => {
let replacedContent = contents.replace(/<\/noscript><\/div>/g, '</noscript></div></div>')
return replacedContent;
}
You can then use parsePostContents
here:
<section
className="post-content"
dangerouslySetInnerHTML={{ __html: this.parsePostContents(post.content)}}
/>
AFAIK @TylerBarnes and the Gatsby team are current working on full fledged solution to Wordpress. So hopefully this ties you over for the moment
from gatsby-wordpress-inline-images.
@garethgd My colleague has copied the plugin to a local plugin and made some changes on the code. This resolves it for now. He may consider a pull request.
Oh and wrapping the <img>
in a <figure>
is a must to get the closing tag problem solved.
from gatsby-wordpress-inline-images.
Hey all, @garethgd is correct, we're currently working on a completely new WP source plugin that uses WPGraphQL and the functionality of this plugin will be built directly into the source plugin. All my attention has been focused there as the plan is to deprecate gatsby-source-wordpress@v3 and our usage of the REST api. There are too many unavoidable issues with using an untyped API. If anyone is interested in maintaining this package let me know!
from gatsby-wordpress-inline-images.
Related Issues (20)
- No blur-up effect? HOT 3
- baseUrl option is being ignored
- Question: how does setting entity.content work?
- Adding wrapper styles
- Don't work using searchAndReplaceContentUrls HOT 1
- inline image urls with pathPrefix HOT 1
- original filenames with sizes pattern HOT 12
- Add more detailed explanations to Readme HOT 3
- Getting [ The "critical" prop is now deprecated ] HOT 6
- TypeError: Cannot read property replace of undefined HOT 4
- gatsby-wordpress-inline-images does not work for me, help appreciated HOT 4
- Try to download the image with the original URL HOT 2
- Queston: How to implement WebP? HOT 1
- Does not seem to work with WordPress v5.5 HOT 1
- Invalid plugin option - "plugins" must contain 0 items HOT 1
- Some settings stopped working in v1 HOT 16
- Add caching HOT 3
- Appears to attempt remote image fetching from localhost. HOT 4
- why does it return <html> and <body>? HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gatsby-wordpress-inline-images.