ngneat / content-loader

⚪️ SVG component to create placeholder loading, like Facebook cards loading.

Home Page:https://netbasal.com/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Safari renders a black block when used in any route different than '/'

pzmuda13 opened this issue · comments

In routes different than home page - '/' all of loaders are black blocks. This happens only in safari - desktop and mobile.

I reproduced this bug in posted demo app. I upgraded the lib version to 2.0.0

The same is happening in my application using angular 7.

https://ngx-content-loader-hqrrey.stackblitz.io - this works fine
https://ngx-content-loader-hqrrey.stackblitz.io/route - this is broken

link to editor:
https://stackblitz.com/edit/ngx-content-loader-hqrrey

Try in the original repo. This is an Angular clone.

According to response from original repo - danilowoz/react-content-loader#93 (comment) there is issue related to urls. The solution is removing base href and use injection token instead - https://angular.io/api/common/APP_BASE_HREF

Additional using cli to set assets base location there is provided flag "--deploy-url". For me when all assets are directly on server also was required to add '/' before all src used in html

Thanks, closing for now.

According to response from original repo - danilowoz/react-content-loader#93 (comment) there is issue related to urls. The solution is removing base href and use injection token instead - https://angular.io/api/common/APP_BASE_HREF

Additional using cli to set assets base location there is provided flag "--deploy-url". For me when all assets are directly on server also was required to add '/' before all src used in html

This hack work only if your base href was "/", otherwise static assets from app assets folder will fail to load.