---
schema_version: "1"
id: 880a2950a21ff6f4af20fe2ccf74da7575ebeefbc88825a2383468f4c427127b
title: Chatter Feed Context Considerations
collection: developer
version: current
locale: en-us
portal_url: https://docs.salesforce.com/developer/current/en-us/platform/canvas-framework/guides/platform-connect/using/chatter/canvas-apps-chatter-feed-context-considerations.md
canonical_url: https://developer.salesforce.com/docs/platform/canvas-framework/guide/canvas-apps-chatter-feed-context-considerations.html
source_site: developer.salesforce.com
content_type: documentation
content_hash: eb4671cfdb863e5d6079752574e8dc8a4caefbf030f5b76477dad1cf21894e78
products:
  - Canvas Developer Guide
  - Platform Developer Content
---

# Chatter Feed Context Considerations

When you display a canvas app inside of a feed item, the context information you receive from the signed request or from a `getContext()` call contains information specific to the feed:

-   Location—If the canvas app is in the feed, then the `Environment.displayLocation` field contains the value `ChatterFeed`.
-   Parameters—When you create a feed item that contains a canvas app, you can specify a JSON string as the parameters value. When the canvas app receives the context, the parameters in the feed item will be contained in the `Environment.Parameters` object.
-   Size—The `Environment.Dimensions` object contains information about the size of the canvas app.

    -   The canvas app height defaults to 100 pixels.
    -   The canvas app width defaults to 420 pixels, which is the same as the maximum width of a canvas app in the feed.
    -   The maximum height of a canvas app in the feed is 400 pixels.
    -   The maximum width of a canvas app in the feed is 420 pixels.
    -   This code snippet shows the default size values of a canvas app in the feed:

        ```nolang
        "dimensions":
        {
            "width": "420px",
            "height": "100px",
            "maxHeight": "400px",
            "maxWidth": "420px"
        }
        ```

    -   The feed is a fixed width of 420 pixels. For example, if you resize your canvas app to be 200 pixels, the feed width remains 420 pixels.
    -   You can use the `resize()` method in the Canvas SDK to change the values of your canvas app up to the `maxHeight` and `maxWidth`.

**See Also**  


-   [Canvas Apps in the Chatter Feed](https://developer.salesforce.com/docs/platform/canvas-framework/guide/canvas-apps-in-chatter-feed.md)
-   [Environment](https://developer.salesforce.com/docs/platform/reference/environment-object.md)
-   [Dimensions](https://developer.salesforce.com/docs/platform/reference/dimensions-object.md)
-   [Resizing a Canvas App](https://developer.salesforce.com/docs/platform/canvas-framework/resizing/canvas-app-resizing.md)
-   [Chatter Feed Canvas App Access Considerations](https://developer.salesforce.com/docs/platform/canvas-framework/guide/canvas-apps-chatter-feed-app-access-considerations.md)

