Serverless data portal and css/html

39 views
Skip to first unread message

Anthony Weaver

unread,
Mar 20, 2026, 7:48:55 AM (8 days ago) Mar 20
to Discuss
I understand that content for the serverless data portals pages are specified in markdown with the ability to use MDX (according to this https://www.globus.org/portals/serverless)

My question is can we also include css and some html?  I've tried a few things and it doesn't seem to work but I also could be doing things wrong.  Here's an example of what I'm trying to do

<link href="style.css" rel="stylesheet"></link>
.....
<div class="centered">
    <a href="https://www.youtube.com/watch?v=Z1-GvBwbJ9Q">
        <img src="https://img.youtube.com/vi/Z1-GvBwbJ9Q/0.jpg" alt="Link to nature conservation talk">
    </a>
</div>


Joe Bottigliero

unread,
Mar 20, 2026, 10:02:15 AM (8 days ago) Mar 20
to Anthony Weaver, Discuss
Yes, MDX should support this. There are a few things you can check:

1. <link href="style.css" rel="stylesheet"></link>, first I'd verify that this asset is resolving properly on its own for your portal by directly accessing the CSS file directly.
    - For the Search and Data portal generators, this file would be expected to be at: {repository}/content/assets/style.css, which would result in the file being hosted at {host}/style.css 
2. Likely not the issue, but explicitly closing the <img /> tag will avoid some potential processing errors.

My hunch is that 1 might be the issue here; Those generators will only copy files in content/assets/* to public-accessible paths, top-level files in content are treated as pages.



Anthony Weaver

unread,
Mar 20, 2026, 10:07:41 AM (8 days ago) Mar 20
to Joe Bottigliero, Discuss
Joe,

You say MDX should support this, then do I need to call my file index.mdx?  If so, then I ran into another issue for which I opened up a github issue.
Just to recap that issue here, I created an index.mdx file with content

# Project overview

In our rapidly shifting environment, wildlife faces challenges of urbanization, climate change, and poor habitat quality. Healthy and connected natural lands play an increasingly important role in supporting biodiversity and aiding in restoring ecosystem function.

This research uses a range of monitoring techniques to assess mammal and bird populations in Lancaster and York counties.  We are interested in three
metrics to determine the health of an ecosystem

- Biodiversity: Typically, healthier ecosystems have a greater variety of species.
- Ecological function: A healthy ecosystem has many ongoing processes, such as decomposition, herbivory, predation, and photosynthesis.
- Ecosystem resilience: This is an ecosystem’s ability to recover from a disturbance such as a heat wave or prolonged drought.

Learn more about this research and its findings in the Nature Hour presentation linked below.

<YouTube youTubeID="Z1-GvBwbJ9Q">

**Note:** Scientific study or research on Lancaster Conservancy’s nature preserves requires advanced approval. If interested, please use the following form to submit your request:

[https://www.lancasterconservancy.org/event-notice/](https://www.lancasterconservancy.org/event-notice/)

Please note that outside of approved scientific study or research, the Conservancy’s rules and regulations do not allow for game camera or drone use.

My build failed with the following error:

Node.js 20 actions are deprecated. The following actions are running on Node.js 20 and may not work as expected: actions/checkout@v4, actions/configure-pages@v5, actions/github-script@v7, actions/setup-node@v4. Actions will be forced to run with Node.js 24 by default starting June 2nd, 2026. Please check if updated versions of these actions are available that support Node.js 24. To opt into Node.js 24 now, set the FORCE_JAVASCRIPT_ACTIONS_TO_NODE24=true environment variable on the runner or in your workflow file. Once Node.js 24 becomes the default, you can temporarily opt out by setting ACTIONS_ALLOW_USE_UNSECURE_NODE_VERSION=true. For more information see: https://github.blog/changelog/2025-09-19-deprecation-of-node-20-on-github-actions-runners/

Tony
Office: STA 007
Research Computing Programmer & Systems Administrator

Joe Bottigliero

unread,
Mar 20, 2026, 10:40:39 AM (8 days ago) Mar 20
to Anthony Weaver, Discuss
Yes – your file will only be processed as MDX if you use the '.mdx' extension. 

It is a little difficult to triage your markup in email contents, since syntax might be being unexpectedly dropped... That said, in the contents you provided <YouTube youTubeID="Z1-GvBwbJ9Q"> would not be valid HTML or MDX (JSX) which would cause a build failure. 

I'm thinking it might be easier to move the conversation over to the GitHub issue for better code support – I'll continue to follow up there.

Screenshot 2026-03-20 at 9.29.03 AM.png

Reply all
Reply to author
Forward
0 new messages