egil / Htmxor

Supercharges Blazor static server side rendering (SSR) by seamlessly integrating the Htmx.org frontend library.
MIT License
109 stars 12 forks source link

UseEmbeddedHtmx? #60

Closed StefH closed 2 months ago

StefH commented 2 months ago

The comment in HtmxHeadOutlet is as follows:

/// <summary>
/// Gets or sets whether or not to add the scripts thats that reference the embedded version of Htmx. Default is <see langword="true"/>.
/// </summary>
/// <remarks>
/// If this set to <see langword="false"/>, include the <c>_content/Htmxor/htmxor.js</c> your application manually.
/// </remarks>
[Parameter] public bool UseEmbeddedHtmx { get; set; } = true;

But when setting this to false, in addition to "include the _content/Htmxor/htmxor.js your application manually", I also need to reference the javascript file for htmx myself, correct?

(BTW I don't understand why I would need to include the _content/Htmxor/htmxor.js your application manually) ?

egil commented 2 months ago

Thanks for pointing this out.

The remarks were wrong. If you look at the rest of the code, you see it only excludes the embedded htmx.js file. So, now the docs are right, and as the docs say, you do need to reference your own version of htmx.