Dear bros,
I facing the same issue, is there any solution for this?
Details as:
11The theme could not be compiled:
Error: Undefined variable.
,
30 | @media screen and (min-width: $screen-lg) {
| ^^^^^^^^^^
'
D:\newapp-main\themesource\datawidgets\web\gallery.scss 30:39 @import
D:\newapp-main\themesource\datawidgets\web\main.scss 7:9 @use
D:\newapp-main\deployment\sass\main.scss 7:1 root stylesheet---
Thank for support
Hard to tell. Just now tried the same, created a new app using the blank template. And that worked fine. If this gets you stuck, then this is not the first experience you want with Mendix. To get going, try another template or even better, try to start using the Base-application: https://marketplace.mendix.com/link/component/117760/Tieka/Base-application
This base application is has a lot of entities and functions that you will be using in your apps and it shows you how an application should be built up, having no errors or warnings, no superfluous page- and popup-templates, no duplicate jar-files, nice modular setup, etc.
Have fun
Go to App > Select Synchronize App Directory
Then run application again.
Hope it will help!
Hi,
This error usually happens when the Atlas theme was not compiled correctly or the theme cache is corrupted. Mendix compiles the theme using Node + Sass, and if the compiled files or cache are broken, you will see errors like:
The theme could not be compiled Error reading ./theme.compiled.css.map: Cannot open file
Even though the file exists, the compiler sometimes cannot read it due to a corrupted deployment folder or incomplete theme build.
The fix is straightforward.
In Mendix Studio Pro:
Project → Clean Deployment Directory
Then run the app again.
This forces Mendix to:
theme.compiled.css and .map filesIn most cases this alone fixes the problem.
If the error still appears:
deployment
Mendix will rebuild everything from scratch.
Theme compilation requires Node.js.
Check your version:
node -v
Recommended versions for Mendix 9.x are usually:
Node 16 LTS or Node 18 LTS
If Node is missing or incompatible, the theme compilation step can fail.
Sometimes the theme folder becomes corrupted.
Go to:
App → App Settings → Atlas UI Resources
Click:
Update Atlas UI Resources
This refreshes the theme files.
Run:
Project → Clean Deployment Directory
before starting the app the first time.
This error is usually caused by a corrupted compiled theme or deployment cache.
The correct fix is:
After that the theme will compile correctly and the app will run.