I am currently using ngboilerplate from: https://github.com/ngbp/ngbp
I want to include the 'ui.bootstrap.datepicker' from UI-Bootstrap (Twitter Bootstrap written natively in AngularJS). The problem is that this doesn't seem to be included in the latest version of ngboilerplate. Does anyone know how I can add this accordingly to the style of ngboilerplate.
This means that other developers can load it as a dependency with bower install.
After trying a couple of things it seems to be quite easy actually. I'll just answer this question in case someone else has the same problem.
I needed to install a new version of UI-Bootstrap. This can be done with bower by executing (on windows):
bower install angular-bootstrap
But this will give you a whole lot of other problems with dependencies.
To resolve this I use this bower.json:
{
"name": "Your-app",
"version": "0.3.1",
"devDependencies": {
"angular": "1.2.4",
"angular-mocks": "1.2.4",
"bootstrap": "3.0.3",
"angular-bootstrap": "0.10.0",
"angular-ui-utils": "0.0.3"
},
"dependencies": {
"angular-ui-router": "0.2.8-bowratic-tedium"
},
"resolutions": {
}
}
Another problem I had was that the LESS code for bootstrap isn't up to date. Instead I just included the bootstrap.css in my main.less file.
Related
I have installed some purescript packages using bower and here is my bower.json file.
{
"name": "halogen-cube",
"ignore": [
"**/.*",
"node_modules",
"bower_components",
"output",
"dist"
],
"dependencies": {
"purescript-prelude": "^3.1.1",
"purescript-console": "^3.0.0",
"purescript-halogen": "^2.0.0",
"purescript-js-timers": "^3.0.0",
"purescript-halogen-svg": "*"
},
"devDependencies": {
"purescript-psci-support": "^3.0.0"
}
}
I wanted to add purescript-web-uievents package so I added "purescript-web-uievents" : "^2.0.0" to my bower.json file and installed all packages again.
But after that, when I run building app, I am getting this issue.
module Data.Map has been defined multiple times:
What should I do to fix this issue?
Thanks in advance.
This error is the result of the same module name existing in two different dependencies. This can happen when a module is moved from one package to another.
In the case of Data.Map, at one point it was a part of purescript-maps. However, this package is now deprecated; and Data.Map was moved to purescript-ordered-collections.
My guess is that you have one dependency that transitively includes purescript-maps while another depends on purescript-ordered-collections.
I am attempting to bower install a variety of leaflet packages. Recently, leaflet upgraded to version 1.1.0 from 1.0.3 which broke several supported libraries. Until the community can fix the issues, I need to have leaflet 1.0.3 installed. Below is part of my bower.json:
"dependencies": {
"angular": "~1.5.0",
"angular-cookies": "~1.5.0",
"angular-bootstrap": "~2.4.0",
"angular-ui-router": "^0.3.2",
"angular-animate": "~1.5.8",
"bootstrap": "^3.3.7",
"font-awesome": "^4.7.0",
"normalize-css": "~3.0.3",
"modernizr": "~3.2.0",
"angular-smart-table": "^2.1.8",
"angular-websocket": "^2.0.0",
"angular-pageslide-directive": "^2.1.4",
"ng-scrollbars": "^0.0.11",
"angular-bootstrap-lightbox": "^0.12.0",
"angular-leaflet-directive": "leaflet-directive#^0.10.0",
"Leaflet.extra-markers": "^1.0.6",
"esri-leaflet": "2.0.7",
"angular-bootstrap-toggle": "^0.1.2",
"leaflet-search": "2.7.0",
"leaflet-draw": "0.4.9"
},
"devDependencies": {
"angular-mocks": "~1.4.7"
},
"resolutions": {
"angular": "^1.4.10",
"angular-bootstrap": "~2.4.0",
"leaflet": "1.0.3"
}
However, when I try to force the bower installation using the resolutions, I end up with the following:
I have another instance of this application running, and it still has 1.0.3 from a prior build. It is also using leaflet-draw 0.4.9, leaflet-search 2.7.0, etc... so I know that the 1.0.3 version is compatible.
Looking at each individual package, each bower.json only requires that leaflet: "^1.0.0".
Why is the bower resolution being ignored and not installing 1.0.3? Why is it not even giving me the option to choose 1.0.3 from the list? I considered downloading a local copy and doing an override, but that is not a preferred solution.
I get this warning building my asp.net core project on teamcity, and also appears as a warning in visual studios:
Dependency specified was Foo.Client >= 1.0.0-* but ended up with Foo.Client 1.0.25523.
I don't understand why this doesn't match. I can't seem to find any documentation on how to make these wildcard strings.
1.0.25523 is a copy a replace operation I do on my build server to reflect the build number. It's not something I'd like to directly reference, I'm just confused as to why my 1.0.0-* isn't accepting something that looks just to differ by patch version.
My package config looks something like this:
{
"version": "1.0.0-*",
"dependencies": {
"Foo.Bar.Client": "1.0.0-*",
},
"frameworks": {
"net46": {
"dependencies": {
"Foo": {
"target": "project"
}
},
"frameworkAssemblies": {
}
}
}
}
And then the substitution is made here and in the Foo.Bar.Client project.json to change "version": "1.0.0-*" to "version": "1.0.25523"
There should be a *.nuspec file for your project, which will have the information about which package version you're using. From your error message, it seems that the package version in this file is 1.0.0 whereas you'll want to change this to 1.0.25523 I think.
You can also check here for some more information.
I get the following error when trying to use an X509Certificate2UI in VS Code:
The type or namespace name 'X509Certificate2UI' does not exist in the namespace 'System.Security.Cryptography.X509Certificates' (are you missing an assembly reference?) [netcoreapp1.1]
I've found a few sites that indicate the solution is to add the system.security.dll assembly, but these responses don't seem to be catered toward VS Code. I've already added the X509Certificates dependency to the project.json file, which doesn't seem to do me much good:
},
"dependencies": {},
"frameworks": {
"netcoreapp1.1": {
"dependencies": {
"Microsoft.NETCore.App": {
"type": "platform",
"version": "1.1.0"
},
"System.Security.Cryptography.X509Certificates": "4.3.0" //"4.3.0-*"
},
"imports": "dnxcore50"
}
Any help would be greatly appreciated :)
-Nate
X509Certificate2UI is not part of .NET Core. It's a Windows-only class, and a UI class at that, and it was not carried over.
You will have to move to a UI-free solution, or cross-compile to target .NET Framework.
this is a part of my bower.json:
"overrides": {
"tinymce-dist": {
"main": [
"tinymce.js",
"themes/modern/theme.js",
"plugins/*/plugin.js"
]
}
},
For the reason of this Issue, I want to specify the version of tinymce-dist to 4.3.12. But how does it work? Something like adding "version": "4.3.12" doesn't work.
Thank you!
Type the command in the project root. Remove tinymce-dist first and reinstall it in version 4.3.12. Then you solve the problem.
$ bower uninstall --save tinymce-dist
$ bower install --save tinymce-dist#4.3.12
Refer to the doc,your bower.json should adds the dependency specification. The command above do the jobs for you.
"dependencies": {
"tinymce-dist": "4.3.12"
},