You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Nativescript 3.4.0
try to import a theme @import 'nativescript-theme-core/css/core.dark.css';
Actual: The theme is not going to be applied
The generated code will be: @import url(/Users/vhristov/Downloads/NSPlayground/app/nativescript-theme-core/css/core.dark.css);
Importing scss file is working @import '~nativescript-theme-core/scss/dark'.
But in some cases you might want to import a css file.
In case you decide to switch to scss from css or you want to use some existing css.
is there any workaround ?
using @import '~nativescript-theme-core/css/dark' gives below error
Error: File to import not found or unreadable: E:\nativescript\HelloWorld
node_modules\nativescript-theme-core\css\dark.
Parent style sheet: E:/nativescript/HelloWorld/app/app.scss
on line 1 of app/app.scss
@bhavincb@T0T4R4 The sample demo in the plugin's repo imports the light theme without any issues using your approach. Can you provide a demo that reproduces the issues you experience?
Notice that v1.5.0 of the plugin has been released.
Activity
radeva commentedon Jan 5, 2018
Hi @vhristov5555 ,
Could you try to import the scss file instead of the css? I.e.:
@import '~nativescript-theme-core/scss/dark'.
Read more about SASS Usage in NativeScript documentation.
vhristov5555 commentedon Jan 5, 2018
Hi,
Importing scss file is working @import '~nativescript-theme-core/scss/dark'.
But in some cases you might want to import a css file.
In case you decide to switch to scss from css or you want to use some existing css.
radeva commentedon Jan 5, 2018
I'm marking support for importing css in scss as a feature.
[-]Import of themes is not working correctly[/-][+]Support import of CSS in SCSS[/+]bhavincb commentedon Feb 22, 2018
is there any workaround ?
using @import '~nativescript-theme-core/css/dark' gives below error
Error: File to import not found or unreadable: E:\nativescript\HelloWorld
node_modules\nativescript-theme-core\css\dark.
Parent style sheet: E:/nativescript/HelloWorld/app/app.scss
on line 1 of app/app.scss
any workaround available?
T0T4R4 commentedon Mar 22, 2018
this fails with the file not found error :
@import '~nativescript-theme-core/scss/dark';this works but it is useless from within a scss file :
@import '~nativescript-theme-core/css/dark.css';I am only working in scss so i need the first one to work.
zbranzov commentedon Apr 12, 2018
@bhavincb @T0T4R4 The sample demo in the plugin's repo imports the light theme without any issues using your approach. Can you provide a demo that reproduces the issues you experience?
Notice that v1.5.0 of the plugin has been released.
bhavincb commentedon Apr 13, 2018
hii @zbranzov ,
mine problem is solved by installing
node-sassglobally.