Skip to content

feat: replace hardcoded org UUID in shortcode calls with theme-level slack-invite #235

Description

@hortison

Background

The academy-theme now provides an org-id shortcode (see layer5io/academy-theme#215) that dynamically extracts the organization UUID from the current learning-path page's directory path (learning-paths/{orgID}/...). It also provides a generic slack-invite shortcode at the theme level.

Current state

Content files in this repo call org-namespaced shortcodes, hardcoding the org UUID as part of the shortcode name:

{{< d011fd20-a3f5-4480-883b-dfb34321d168/slack-invite link="..." >}}

This creates a maintenance burden: if the UUID changes or the org directory is renamed, all content files referencing it break.

Requested change

Once academy-theme#215 is merged and the theme version is bumped in go.mod:

  1. Replace all occurrences of {{< d011fd20-a3f5-4480-883b-dfb34321d168/slack-invite link="..." >}} with {{< slack-invite link="..." >}}
  2. Remove layouts/shortcodes/d011fd20-a3f5-4480-883b-dfb34321d168/slack-invite.html if it exists locally (the theme now owns it)
  3. Use {{< org-id >}} anywhere the UUID is needed as a text value in content

References

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Fields

No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions