Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pnotify v5.1.0 and angular 9 #388

Open
raymond10 opened this issue Apr 23, 2020 · 14 comments · May be fixed by #399
Open

pnotify v5.1.0 and angular 9 #388

raymond10 opened this issue Apr 23, 2020 · 14 comments · May be fixed by #399

Comments

@raymond10
Copy link

Hi,

I use latest version of pnotify in my ng9 app but I'm facing of some issues I don't understand.

1 - I have error in in node_modules/@pnotify/core/Stack.d.ts line 1
TS wants import { Notice } from './'; instead of import Notice from './';

Stack.d.ts img
Capture d’écran 2020-04-23 à 16 12 53

TS error img
Capture d’écran 2020-04-23 à 16 12 46

2 - On notification, it displays on bottom left of my screen with no icons, no click button etc.. instead of top right of my screen

Notification img
Capture d’écran 2020-04-23 à 16 07 52

Code img
Capture d’écran 2020-04-23 à 16 11 19

Thanks for help

@CarlosScarpato
Copy link

CarlosScarpato commented Apr 29, 2020

i have the same error .... in my app ...
but:

I've changed index.d.ts, at line 232,
From : export abstract class Notice extends NoticeProperties
To : export default abstract class Notice extends NoticeProperties

and the error go away .... i think that, we have two abstract classes declared in this file, however, angular doesn't know what class is the "main" class of the file.

i think that it's the answer!
See ya

@raymond10
Copy link
Author

Hi,
Thanks for reply (I go to modify in node_modules) but what the developer think about these issues ?
Do they will be fixed in the next version to fit with angular 9 ?

@raymond10
Copy link
Author

Hi,

I made change in the core/index.d.ts but I have the same issue. The notification display but no icon, no button and always in bottom left.

Thanks

@CarlosScarpato
Copy link

so, i've tested yesterday, and i got the same problem ... with pnotify, so, now, i saw that the developer has made some changes ... i'll try it again ...

see ya

@CarlosScarpato
Copy link

Hi,

I made change in the core/index.d.ts but I have the same issue. The notification display but no icon, no button and always in bottom left.

Thanks

Bro .... the error continues .... let wait other commit from developer ....

tks

@raymond10
Copy link
Author

Hi,

Thanks for your assistance.
I wait for the developer.

see ya

@hertz1 hertz1 linked a pull request Aug 7, 2020 that will close this issue
@jarodsmk
Copy link

Looks like both of these PRs fix this issue in differing ways:
#399
#398

@jarodsmk
Copy link

@hperrin if you get a moment, would you mind taking a look at them please? 🙌

@jarodsmk
Copy link

Managed to recreate this on codesandbox.io with Angular 11.2 which is interesting because no errors are thrown there, which is why I think this was overlooked

Easy way recreate this issue:

  1. ng new PNotifyTest
  2. npm i --save pnotify
  3. (Add code either from the PNotify Angular docs or from the provided codesandbox.io example)
  4. ng s

@hperrin
Copy link
Member

hperrin commented Feb 22, 2021

I'm looking into this now.

@hperrin
Copy link
Member

hperrin commented Feb 22, 2021

Is this only happening with Angular, or with any project using TypeScript?

@jarodsmk
Copy link

Is this only happening with Angular, or with any project using TypeScript?

Can't say for sure, I think everyone who commented here experienced it with Angular projects -
I suspect Typescript projects may be affected too

@hperrin
Copy link
Member

hperrin commented Feb 22, 2021

Since Svelte now supports TypeScript natively, I may be able to do away with the type definition file and convert PNotify to typed Svelte.

@jarodsmk
Copy link

jarodsmk commented Sep 2, 2021

Hey @hperrin - just wanted to follow up on this? :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants