Problems importing fontawesome
I have problems when I want to import fontawesome and I do not know how to fix it.
I’m developing a biballs style aplicaction.
An application donejs runs on an express server launched by done-ssr-middleware.
These are my sources and errors:
In Express server.js
var ssr = require('done-ssr-middleware');
app.use('/', ssr({
config: __dirname + '/public/package.json!npm'
}));
in donejs app.js
import $ from 'jquery';
import 'bootstrap/less/bootstrap.less!';
import 'font-awesome/css/font-awesome.min.css';
In browser console (url : http://localhost:8080)
ERROR - GET http://localhost:8080/fonts/fontawesome-webfont.woff?v=4.6.1
In shell console
Received client connection
TypeError: Cannot define property:fonts/fontawesome-webfont.ttf?v, object is not extensible.
at Function.defineProperty (native)
at Function.define.property (file:/home/alejandro/workspaces/sinergis-mobile/public/node_modules/can-define/can-define.js:222:9)
at Object.defineExpando (file:/home/alejandro/workspaces/sinergis-mobile/public/node_modules/can-define/define-helpers/define-helpers.js:42:20)
at DefineMap.set (file:/home/alejandro/workspaces/sinergis-mobile/public/node_modules/can-define/map/map.js:199:37)
at DefineMap.setProps (file:/home/alejandro/workspaces/sinergis-mobile/public/node_modules/can-define/map/map.js:79:18)
at DefineMap.set (file:/home/alejandro/workspaces/sinergis-mobile/public/node_modules/can-define/map/map.js:197:29)
at DefineMap.attrHelper (file:/home/alejandro/workspaces/sinergis-mobile/public/node_modules/can-route/can-route.js:90:9)
at Function.canRoute.attr (file:/home/alejandro/workspaces/sinergis-mobile/public/node_modules/can-route/can-route.js:935:20)
at Function.canRoute.setState (file:/home/alejandro/workspaces/sinergis-mobile/public/node_modules/can-route/can-route.js:331:12)
at Function.ready (file:/home/alejandro/workspaces/sinergis-mobile/public/node_modules/can-route/can-route.js:607:14)
at /home/alejandro/workspaces/sinergis-mobile/node_modules/done-ssr/lib/make_render.js:14:15
at /home/alejandro/workspaces/sinergis-mobile/node_modules/done-ssr/lib/index.js:137:5
at Task.run (/home/alejandro/workspaces/sinergis-mobile/node_modules/can-zone/lib/zone.js:37:17)
at Zone.run (/home/alejandro/workspaces/sinergis-mobile/node_modules/can-zone/lib/zone.js:197:26)
at /home/alejandro/workspaces/sinergis-mobile/node_modules/done-ssr/lib/index.js:136:16
at tryCatchReject (/home/alejandro/workspaces/sinergis-mobile/node_modules/steal/src/loader/loader.js:1183:30)
My package.json
{
"name": "sinergis-mobile",
"version": "0.0.0",
"description": "An awesome DoneJS app",
"homepage": "",
"repository": {
"type": "",
"url": ""
},
"author": {
"name": "",
"email": "",
"url": ""
},
"license": "UNLICENSED",
"private": true,
"scripts": {
"test": "testee test.html --browsers firefox --reporter Spec",
"start": "done-serve --port 8080",
"develop": "done-serve --develop --port 8080",
"build": "node build"
},
"main": "index.stache!done-autorender",
"files": [
"."
],
"keywords": [],
"steal": {
"main": "index.stache!done-autorender",
"directories": {
"lib": "."
},
"configDependencies": [
"live-reload",
"node_modules/can-zone/register"
],
"plugins": [
"done-css",
"done-component",
"steal-less",
"steal-stache"
],
"envs": {
"server-production": {
"renderingBaseURL": "/dist"
}
},
"serviceBaseURL": ""
},
"dependencies": {
"bootstrap": "^3.3.7",
"can-component": "^3.0.7",
"can-connect": "^1.3.8",
"can-define": "^1.0.17",
"can-route": "^3.0.8",
"can-route-pushstate": "^3.0.3",
"can-set": "^1.1.0",
"can-stache": "^3.0.20",
"can-view-autorender": "^3.0.4",
"can-zone": "^0.6.6",
"done-autorender": "^1.0.0",
"done-component": "^1.0.0",
"done-css": "^3.0.0",
"done-serve": "^1.0.0",
"font-awesome": "^4.7.0",
"generator-donejs": "^1.0.0",
"gentelella": "^1.3.0",
"jquery": "^3.2.1",
"steal": "^1.3.1",
"steal-less": "^1.2.0",
"steal-stache": "^3.0.5"
},
"devDependencies": {
"donejs-cli": "^1.0.0",
"funcunit": "^3.2.0",
"steal-qunit": "^1.0.1",
"steal-tools": "^1.2.0",
"testee": "^0.3.0",
"can-fixture": "^1.0.13"
}
}
I appreciate any help because I’m blocked !!