question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Improve image node

See original GitHub issue
  • Update image syntax so that if it is on a line by itself, it is treated as a block, otherwise treat it as an inline element.
    • The default schema would render block-level images in a figure instead of a p, but this behavior would be possible to override in a custom node definition’s transform function
  • Update image syntax to allow passing additional attributes
    • E.g. ![alt](/href width=10 height=10 foo={arbitrary: "markdoc stuff"})
  • Test that the image/link syntax works with GitHub flavored Markdown, or we have a story for that.

Issue Analytics

  • State:open
  • Created a year ago
  • Reactions:2
  • Comments:5 (4 by maintainers)

github_iconTop GitHub Comments

2reactions
mfix-stripecommented, Aug 18, 2022

@nvanexan if you are using and Markdoc specific syntax (e.g. annotations), then those will not show up correctly in GitHub or iAWriter, until they support Markdoc syntax. If you are not, and you just use standard Markdown (e.g. ![foo](/url "title")), then it will still work in both all the contexts.

0reactions
samuelstroscheincommented, Dec 23, 2022

Are images nested in links part of this issue?

I just ran into the issue of using images with links. The following markdown throws { "id": "child-invalid", "level": "warning", "message": "Can't nest 'image' in 'link'" } but is valid on GitHub and a CommonMark reference implementation https://spec.commonmark.org/dingus/.

[![Open in Gitpod](https://gitpod.io/button/open-in-gitpod.svg)](https://gitpod.io/#https://github.com/inlang/inlang)
Read more comments on GitHub >

github_iconTop Results From Across the Web

How To Process Images in Node.js With Sharp
First, you'll chain the resize() method from the sharp instance to resize the image, and save it in the project directory. Second, you'll...
Read more >
Processing images with sharp in Node.js
sharp is a high-performance image processing module for Node.js. This module assists with UGC management by offering an easy solution for ...
Read more >
lovell/sharp: High performance Node.js image processing ...
High performance Node.js image processing, the fastest module to resize JPEG, PNG, WebP, AVIF and TIFF images. Uses the libvips library.
Read more >
Azure Kubernetes Service (AKS) node image upgrade
To speed up the node image upgrade process, you can upgrade your node images using a customizable node surge value. By default, AKS...
Read more >
sharp - High performance Node.js image processing
This module supports reading JPEG, PNG, WebP, GIF, AVIF, TIFF and SVG images. Output images can be in JPEG, PNG, WebP, GIF, AVIF...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found