Skip to content

Default values should be serialized and sent across Block Renderer to the front end. #12951

Closed

Description

@mrpritchett

Is your feature request related to a problem? Please describe.
Creating defaults is something that I love about the Gutenberg attribute definitions. Declaring them with a block that uses serversiderender allows those defaults to be seen in the editor, but not on the front end. Why wouldn't we want to use custom-built defaults on the front end?

Describe the solution you'd like
Let default values be serialized and sent to the front end for server-side rendered blocks.

Activity

  1. added
    [Type] Question
    [Package] Server Side Render
    on Dec 17, 2018
  2. added
    [Status] Blocked
    on Dec 17, 2018
  3. jorgefilipecosta commented on Dec 17, 2018

    @jorgefilipecosta
    Member

    This issue gets solved as soon as Server-side awareness of block types is implemented #2751. The implementation will allow the front end to know the default values of the attributes.

  4. added
    [Type] Enhancement
    and removed
    [Type] Question
    on Feb 19, 2019
  5. skorasaurus commented on Feb 4, 2021

    @skorasaurus
    Member

    Is this now unblocked because of #21065 ?

  6. jorgefilipecosta commented on Apr 26, 2021

    @jorgefilipecosta
    Member

    Closing this issue, as now we have a mechanism for server-side awareness of blocks and API's to retrieve metadata like default attributes on the server.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    [Package] Server Side Render[Status] Blocked[Type] Enhancement

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions