Swagger UI - deepLinking - http-status-code-404

I am using springfox-swagger2 and springfox-swagger-ui. both version 2.9.2
I have enabled deepLinking with this code:
#Bean
public UiConfiguration swaggerUiConfig() {
return UiConfigurationBuilder.builder().deepLinking(true).build();
}
Somehow it suddenly stopped working, it doesnt redirect me to method in link...
It works only on controllers, for example this works
http://localhost:8080/api/swagger-ui.html#/email-controller/
but not this http://localhost:8080/api/swagger-ui.html#/email-controller/getFullEmailListUsingGET
Any ideas?
I tried older version 2.7.0 and there it works...
Edit: I solved this by using version 2.8.0 where deepLinking works correctly for both controllers and operations. Design of 2.8.0 looks like 2.9.2, 2.7.0 was also working but the design was older.

Related

Angular application works on Chrome but not Safari

My website works fine on Chrome but is broken on Apple Mobile Safari.
I have troubleshot the situation and have found that it is the below line of code placed in side of my angular controller that is causing the problem. With out this code everything works fine.
The code takes all images on the page and puts them inside of an array. Anything I can do differently to ensure proper compatibility? Thank you!
$scope.load_picture_cotent = function () {
$scope.pictures = Array.from(
document.querySelectorAll
('div.album [style^="background-image"]')).map
(el=>el.style.backgroundImage.replace(/url\((.*)\)/,'$1')
.replace(/"/g,'')
.replace(/thumbnails/,'highresolution'));
console.log($scope.pictures);
}
You can also view the website here.
Please let me know if you need any more information or would like me to expand my post to include more information.
you are using ECMA 2015 lambda notation, try to wrap this with babel and try it again, did you check the browsers compatibility status with ECMA Script 2015?
Thank you bretanac93.
He was right, I was using a newer version of Javascript than is currently supported by browsers.
He recommended I use Babel which is a compiler that converts new Javascript to a compatible Javascript.
I used babel to compile the compatibility javascript and it works like a charm.

Angular Js - Routing Issue with different old version

I am new to AngularJS and was looking at the "Miguel Castro–AngularJS for ASP.NET MVC Developers" sample downloaded from "http://www.melvicorp.com/downloads.html".
When running the code sample of project 2 (AngularRouting) from Miguel's sample with new version of AngularJs (installed using NuGet), the routing doesn't work and it gives the following error:
[$location:nobase] http://errors.angularjs.org/1.5.6/$location/nobase
If I replace the new version of AngularJs Script files with older ones from Miguel's sample project, it works just fine.
I has clearly something to do with version, but what it is exactly?
Thanks

AngularJS 1.3 with ngbp framework doesn't load in chrome browser when using ng-strict-di

I'm working on an AngularJS web app using the ngbp framework (formerly ng-boilerplate) which by default uses AngularJS 1.2. The project is in early stages so we're experimenting with using AngularJS 1.3 instead of 1.2, as it has some nice features we'd like to make use of. We're also working under the assumption that AngularJS 1.3 will likely be the release version by the time we go live.
So I simply switched the AngularJS version number in the bower.json file and everything seems to work fine in Chrome, Safari, and Firefox except for when I enable strict dependency injection (ng-strict-di). When strict DI mode is on I get the error below (more detail here), but it only occurs in Chrome (FF & Safari both still work as expected).
Failed to instantiate module ng due to:
Error: [$injector:strictdi] function($provide) is not using explicit annotation and cannot be invoked in strict mode
http://errors.angularjs.org/1.3.0-build.3121+sha.a4520a7/...)
at http://localhost:8080/assets/ngbp-0.3.2.js:87:12
at annotate (http://localhost:8080/assets/ngbp-0.3.2.js:3352:17)
at Object.invoke (http://localhost:8080/assets/ngbp-0.3.2.js:4036:21)
at runInvokeQueue (http://localhost:8080/assets/ngbp-0.3.2.js:3964:35)
at http://localhost:8080/assets/ngbp-0.3.2.js:3973:11
at forEach (http://localhost:8080/assets/ngbp-0.3.2.js:338:20)
at loadModules (http://localhost:8080/assets/ngbp-0.3.2.js:3954:5)
at createInjector (http://localhost:8080/assets/ngbp-0.3.2.js:3894:11)
at doBootstrap (http://localhost:8080/assets/ngbp-0.3.2.js:1494:20)
at bootstrap (http://localhost:8080/assets/ngbp-0.3.2.js:1509:12
It seems that for some reason the angular source code itself is failing the strict DI test and thus won't load in the Chrome browser from within the ngbp framework. The above error comes from a fresh clone of ngbp with the only change being the version of AngularJS (1.3), not from our actual project (though the error is the same in both cases). I know that this version of ngbp doesn't officially support Angular 1.3 but as I said the app seems to work just fine with this change, even though it fails this test. I'm wondering if anyone might have some insight into what is causing this error and whether or not it would be ill-advised to proceed with this combination of AngularJS 1.3 and ngbp (version: 0.3.2)? Is there something else within ngbp that needs to be changed along with the version of AngularJS?
If it helps I'm serving up the files locally via cd ../bin; http-server -p 8080. If any other information would help just let me know and I'd be happy to provide it if possible.
Thanks for your time.
EDIT: If it helps I tested on OS X 10.9.4 with the following browser versions:
Chrome (Version 36.0.1985.143)
64-bit Chrome (Version 37.0.2062.94)
Firefox (31.0)
Safari (Version 7.0.5 (9537.77.4))
Looks like you might be using batarang, it does not work well with ng-strict-di. Try disabling batarang from google chrome developer tools and the app should start normally again.
[edit] AngularJS batarang now support ng-strict-di since v0.5.0. This error should no longer happen.

Issue after updating resteasy 3.0.8 NOT FOUND EXCEPTION

after i updated my sample app to resteasy 3.0.8.FINAL the path can't be resolved. Before the update the app was running on resteasy 3.0.6.FINAL without any issues.
I'm using the solution with the ResteasyBootstrap listener. I checked the release notes for 3.0.7 / 3.0.8 but i couldn't find any big breaking change here.
on github you can find my sample app

Angular JS ui-router on Internet Explorer 8

Has anyone gotten the Angular JS ui-router quick-start to run in IE8? The quick start's here:
ui-router quick-start
It's working in chrome but not in IE8.
Thanks!
[Edit]
I have read the ie documentation under angular js but the fix provided doesn't seem to fix the issue (missing forEach method). The fix only addresses issues with angular js and not angular-ui-router.
The only thing that works is from an answer here: AngularJS - IE8 html template. The basically provides an implementation for forEach which is not supported in IE.
Can you try building off of master? There was a pull request merged just after the last release (https://github.com/angular-ui/ui-router/pull/392) that resolved some IE8 issues. Everything else should work fine AFAIK.

Resources