BoldDesk®Customer service software with ticketing, live chat & omnichannel support, starting at $99/mo for unlimited agents. Try for free!
When updating to v25 the scss does not compile anymore:
@use "../node_modules/@syncfusion/ej2-base/styles/material3.scss" as sfBase;
@use "../node_modules/@syncfusion/ej2-buttons/styles/material3.scss" as sfButtons;
If I use @import everything works
@import"../node_modules/@syncfusion/ej2-base/styles/material3.scss";
@import "../node_modules/@syncfusion/ej2-buttons/styles/material3.scss";
But I prefer using@use over @import since @use is more performant
Hi Michael,
Thank you for reaching out to us.
We've carefully reviewed your concern regarding the usage of @use versus @import in your SCSS files. We understand your preference for @use due to its performance benefits, but we'd like to provide some insights into the implementation of Syncfusion styling.
When using @use in SCSS, Sass expects that all variables, mixins, and functions are explicitly defined before they are used. In our case, since we provide multiple UI component libraries, our stylesheets rely on variables defined in our base style file, where we have all the base definition variables for all our components. Some components depend on other stylesheets based on the component hierarchy.
This design ensures that our components have access to consistent styling and functionality. These styles are essential for ensuring the optimal functioning of our components, providing you with comprehensive control over their appearance and behavior.
Additionally, we would like to inform you that we've meticulously configured our variables to prevent any potential conflicts or naming issues with our component styles. So we recommend continuing to use @import to ensure smooth compilation and consistent styling across Syncfusion components.
If you need any further assistance, kindly reach out to us.
Regards,
Mohamed Imran T
Thanks for the clarification. Then I will change back to @import
Hi Michael,
Thanks for your understanding and attention to updating the information.
.
Regards,
Mohamed