Re: Routing ignore

2021-03-21 Thread Greg Keogh
>
> The solution was to edit  the '*onfetch(event)*' *function *in
> *service-worker.published.js* in the *Blazor WebAssembly Client "wwwroot"
> folder *and add a url exclusion for the /swagger folder.
>

Oh drats! I was hoping for something dead simple, but I'll see where it
leads -- *Greg*


Re: Routing ignore

2021-03-21 Thread Dan Cash
Hi Greg--

I understand that you want the '/download/' URL to bypass the Webassembly
service-worker.
Server-side, I'd old-school a server-rewrite (mod-rewrite / IISRewrite /
custom HTTPFilter) or Fiddle the site config handlers.  **sighs**

I found a SO article describing a deployment issue with escaping static
'/swagger' processing (worked OK on kestrel, but broke on IIS; something to
do with Browser cache?)
The solution was to edit  the '*onfetch(event)*' *function *in
*service-worker.published.js* in the *Blazor WebAssembly Client "wwwroot"
folder *and add a url exclusion for the /swagger folder.

   - URL Rewrite exceptions for Blazor WebAssembly Hosted deployment
   



Perhaps this will work for '/downloads/' too?  e.g.

File: * service-worker.published.js*  (You might need to use
'service-worker.js')



async function *onFetch*(event) {
   .
   .

const shouldServeIndexHtml = event.request.mode === 'navigate'
&& !event.request.url.includes('/connect/')
&& !event.request.url.includes('/Identity/')*
&& !event.request.url.includes('/**download**/');*

   .
   .

}

HTH

Dan C.



On Mon, 22 Mar 2021 at 13:32, Greg Keogh  wrote:

> (UHF communication band established again)
>
> I have a question about Blazor Webassembly app routing, but I think Blazor
> uses the same routing logic as MVC (I think) so the question might be more
> general.
>
> Is there a way of configuring some routes to be ignored and passed on to
> be processed as static content?
>
> For example I want anything under /download/ to be ignored by the Blazor
> spp and just be static files for download. I've searched until my fingers
> ache, but I'll bet there's a trick I'm missing .. I hope.
>
> *Greg K*
>


-- 
Dan Cash
-m. 0411 468 779
-e. dan.c...@gmail.com

F.A.B. Information Systems Pty Ltd   ABN 16 084 146 261


Re: [OT] UHF Check

2021-03-21 Thread Dan Cash
Check.

On Mon, 22 Mar 2021 at 13:19, Greg Keogh  wrote:

> My last 3 posts to this group bounced, and I notified David at Codify, but
> received no reply. Is the group active? -- *Greg Keogh*
>


-- 
Dan Cash
-m. 0411 468 779
-e. dan.c...@gmail.com

F.A.B. Information Systems Pty Ltd   ABN 16 084 146 261


Routing ignore

2021-03-21 Thread Greg Keogh
(UHF communication band established again)

I have a question about Blazor Webassembly app routing, but I think Blazor
uses the same routing logic as MVC (I think) so the question might be more
general.

Is there a way of configuring some routes to be ignored and passed on to be
processed as static content?

For example I want anything under /download/ to be ignored by the Blazor
spp and just be static files for download. I've searched until my fingers
ache, but I'll bet there's a trick I'm missing .. I hope.

*Greg K*


Re: [OT] UHF Check

2021-03-21 Thread Alan Ingleby
Working for me.?

On Mon, 22 Mar 2021 at 13:24, kirsten greed  wrote:

> I see this but not the last 3
>
> On Mon, Mar 22, 2021 at 2:19 PM Greg Keogh  wrote:
>
>> My last 3 posts to this group bounced, and I notified David at Codify,
>> but received no reply. Is the group active? -- *Greg Keogh*
>>
>

-- 
Alan Ingleby


Re: [OT] UHF Check

2021-03-21 Thread kirsten greed
I see this but not the last 3

On Mon, Mar 22, 2021 at 2:19 PM Greg Keogh  wrote:

> My last 3 posts to this group bounced, and I notified David at Codify, but
> received no reply. Is the group active? -- *Greg Keogh*
>


[OT] UHF Check

2021-03-21 Thread Greg Keogh
My last 3 posts to this group bounced, and I notified David at Codify, but
received no reply. Is the group active? -- *Greg Keogh*