forceChatter:publisher

Lets users create posts on records or groups, and upload attachments from any device.

The forceChatter:publisher component is a standalone publisher component you can place on a record page. It works together with the forceChatter:feed component available in the Lightning App Builder to provide a complete Chatter experience. The advantage of having separate components for publisher and feed is the flexibility it gives you in arranging page components. The connection between publisher and feed is automatic and requires no additional coding.

The forceChatter:publisher component includes the context attribute, which determines what type of feed is shown. Use RECORD for a record feed, and GLOBAL for all other feed types.

<aura:component implements="flexipage:availableForAllPageTypes" description="Sample Component">
    <forceChatter:publisher context="GLOBAL" />
    <forceChatter:feed type="Company" />
</aura:component>

This component is supported for Lightning Experience and communities based on the Customer Service template.

Attributes

Attribute Name Attribute Type Description Required?
body Component[] The body of the component. In markup, this is everything in the body of the tag.
context String The context in which the component is being displayed (RECORD or GLOBAL). RECORD is for a record feed, and GLOBAL is for all other feed types. This attribute is case-sensitive. Yes
recordId String The record Id