No puede seleccionar más de 25 temas Los temas deben comenzar con una letra o número, pueden incluir guiones ('-') y pueden tener hasta 35 caracteres de largo.
 
 
 
 
 
 

31 líneas
649 B

  1. let path = require("path");
  2. let { get_app_path, app_list } = require("./utils");
  3. let node_modules_path = path.resolve(
  4. get_app_path("frappe"),
  5. "..",
  6. "node_modules"
  7. );
  8. let app_paths = app_list
  9. .map(get_app_path)
  10. .map(app_path => path.resolve(app_path, ".."));
  11. module.exports = {
  12. includePaths: [node_modules_path, ...app_paths],
  13. quietDeps: true,
  14. importer: function(url) {
  15. if (url.startsWith("~")) {
  16. // strip ~ so that it can resolve from node_modules
  17. url = url.slice(1);
  18. }
  19. if (url.endsWith(".css")) {
  20. // strip .css from end of path
  21. url = url.slice(0, -4);
  22. }
  23. // normal file, let it go
  24. return {
  25. file: url
  26. };
  27. }
  28. };