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

Improve utils methods in all packages #5968

Closed
mertsincan opened this issue Jun 26, 2024 · 3 comments
Closed

Improve utils methods in all packages #5968

mertsincan opened this issue Jun 26, 2024 · 3 comments
Assignees
Labels
Type: Enhancement Issue contains an enhancement related to a specific component. Additional functionality has been add
Milestone

Comments

@mertsincan
Copy link
Member

Use @primeuix/utils package instead of DomHandler, ObjectUtils, ZIndexUtils and EventBus.

@mertsincan mertsincan added the Type: Enhancement Issue contains an enhancement related to a specific component. Additional functionality has been add label Jun 26, 2024
@mertsincan mertsincan added this to the 4.0.0-rc.3 milestone Jun 26, 2024
@mertsincan mertsincan self-assigned this Jun 26, 2024
@dominiksulak
Copy link

Please I need help. When trying to import and use "dom" insted of "DomHandler" (I was updating primeVue from 3.30.2 --> 4.0.0) constantly getting this error: AppMenuItem.vue:5 Uncaught SyntaxError: The requested module '/node_modules/.vite/deps/@primeuix_utils_dom.js?v=4b85fe6c' does not provide an export named 'default' (at AppMenuItem.vue:5:8). I dont know how to import correctly. Thanks a lot!

@dominiksulak
Copy link

Could anybody please response to my question? I need help with switching from EventBus to primeuix/utils package. Thanks a lot!

@mertsincan
Copy link
Member Author

Hi @dominiksulak,

The methods are exported with named export. Please try;

import { addClass } from '@primeuix/utils/dom';
or 
import * as dom from '@primeuix/utils/dom'; 
dom.addClass()

import { EventBus } from '@primeuix/utils/eventbus';

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Enhancement Issue contains an enhancement related to a specific component. Additional functionality has been add
Projects
None yet
Development

No branches or pull requests

2 participants