Skip to content

configure tluma.ai#515

Closed
Ethan-Arrowood wants to merge 1 commit into
mainfrom
tluma
Closed

configure tluma.ai#515
Ethan-Arrowood wants to merge 1 commit into
mainfrom
tluma

Conversation

@Ethan-Arrowood
Copy link
Copy Markdown
Member

@Ethan-Arrowood Ethan-Arrowood requested a review from a team as a code owner June 4, 2026 17:14
Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request integrates the tluma.ai widget into the Docusaurus configuration by loading its script in production and adding its configuration to the head tags. The reviewer suggested conditionally injecting the configuration head tags only in production to match the script loading behavior and avoid polluting the global scope in development.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

Comment thread docusaurus.config.ts
Comment on lines +413 to +422
headTags: [
{
tagName: 'script',
innerHTML: `window.tlumaConfig = {
source: 'harperfast/documentation',
theme: 'auto',
button: 'bottom-right',
};`,
},
],
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

The tluma.ai widget script is only loaded in production (process.env.NODE_ENV === 'production'), but its configuration (window.tlumaConfig) is currently injected into the head tags in all environments, including development. To keep the environments consistent and avoid polluting the global scope with unused configuration in development, we should conditionally inject the headTags only in production.

	...(process.env.NODE_ENV === 'production'
		? {
				headTags: [
					{
						tagName: 'script',
						innerHTML: `window.tlumaConfig = {
			source: 'harperfast/documentation',
			theme: 'auto',
			button: 'bottom-right',
		};`,
					},
				],
			}
		: {}),

@Ethan-Arrowood
Copy link
Copy Markdown
Member Author

I tried this locally; the service seems dead. There is a 401 error when it tries accessing github. 🤷‍♂️ i'll close but we can try this again another time.

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Jun 4, 2026

🧹 Preview Cleanup

The preview deployment for this PR has been removed.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant