Comments (8)
Hi. Please can you try v2.3.0 and if it still doesn't work provide an example that runs on https://stackblitz.com/ ?
from dynamic-marquee.
Hi, updated version to 2.3.0. Switch the tab, there is new error called ''String missing 'px' suffix".
And after build, same issue as mentioned in title of this issue.
Demo link: https://stackblitz.com/edit/angular-router-basic-example-hjrksg?file=app%2Fviews%2Flogin%2Flogin.component.ts
from dynamic-marquee.
Hi, updated version to 2.3.0. Switch the tab, there is new error called ''String missing 'px' suffix".
And after build, same issue as mentioned in title of this issue.
Demo link: https://stackblitz.com/edit/angular-router-basic-example-hjrksg?file=app%2Fviews%2Flogin%2Flogin.component.ts
from dynamic-marquee.
I should be able to prevent that error but I think the root of the issue here is not cleaning up before the component tears down.
In the components where you use the marquee could you call clear()
on it in a ngOnDestroy
function?
More info here: https://angular.io/guide/lifecycle-hooks
from dynamic-marquee.
Core issue is, with the following setup, marquee behaves strangely in dev env and prod env
setup:
this.$marquee = document.getElementById("marquee")!;
this.marquee = new Marquee(this.$marquee, {
rate: -100,
startOnScreen: false,
});
In dev env, marquee works fine i.e text move from left to right.
But in prod, (After ng build), run the dist/
folder.
text appears directly on screen i.e right side of the screen. Why it behaves so ?
preview of the out put: (sorry i am not able to attach picture)
in Dev:
--------------------------------------------------
| Starts here|
--------------------------------------------------
in Prod:
--------------------------------------------------
| Starts here |
--------------------------------------------------
from dynamic-marquee.
Any updates @tjenkinson ?
from dynamic-marquee.
@rakeshnayak360 please have a look at https://stackblitz.com/edit/angular-router-basic-example-pwzpdf
This updates to the latest version and adds the tear down function which hopefully solves the problems.
from dynamic-marquee.
$window.style.position = 'relative';
in marquee.js fixed my issue. Thanks for the update. You made my day :)
from dynamic-marquee.
Related Issues (20)
- Word Wrap? HOT 6
- No room for item. HOT 2
- StartVisible Marquee HOT 7
- clear() is broken HOT 2
- How to start crawl from perticular position? HOT 6
- More than one Spacing issue between the text HOT 6
- Character Overlapping HOT 2
- How to add fetch support from json? HOT 1
- In Angular (above 2 version) getting error 'Cannot find name 'dynamicMarquee' HOT 10
- Is there any callback events available? HOT 6
- Support stop on mouseover? HOT 2
- Javascript error on safari with loop function HOT 3
- Infinite loop when using images in upDown mode HOT 11
- [Question] HTML Content HOT 4
- [Question] Stop on touch? (loop?) HOT 1
- Why this is not working. HOT 6
- Question: loop same element with long activity, DOM slowdown? HOT 2
- Item already exists HOT 5
- Support scroll to item in marquee HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from dynamic-marquee.