Please, tell us how to recreate the issue in as much detail as possible.
Describe the steps to reproduce it.
When trying to set cookies in app.module.ts, no cookies are transmitted and the options for cookies is ignored:
SocketIOModule.forRoot(<url_value>, { debug: true, cookies: ["<name>=<value>; Domain=<domain_value>; Path=/; Expires=<expiration_time>"], forceNew: true, forceWebsockets: true, secure: true })
Is there any code involved?
See above.
The issue is that the interface IOOptions defined in angular/index.d.ts specifies the key as 'cookies' whereas socketio.ios.ts and socketio.android.ts look for key 'cookie'.
Make sure to check the demo app(s) for sample usage
Done.
Make sure to check the existing issues in this repository
One related issue in the past but I believe the solution to that broke the functionality for Angular.
If the demo apps cannot help and there is no issue for your problem, tell us about it
Please, ensure your title is less than 63 characters long and starts with a capital letter.
Which platform(s) does your issue occur on?
Please, provide the following version numbers that your issue occurs with:
"dependencies": { "@angular/animations": "~8.2.6", "@angular/common": "~8.2.6", "@angular/compiler": "~8.2.6", "@angular/core": "~8.2.6", "@angular/forms": "~8.2.6", "@angular/http": "8.0.0-beta.10", "@angular/platform-browser": "~8.2.6", "@angular/platform-browser-dynamic": "~8.2.6", "@angular/router": "~8.2.6", "@owen-it/nativescript-uuid": "0.0.4", "ajv": "^6.10.2", "base-64": "^0.1.0", "lodash": "^4.17.15", "nativescript-angular": "^8.2.1", "nativescript-appversion": "^1.4.2", "nativescript-facebook": "^4.2.1", "nativescript-purchase": "^2.0.13", "nativescript-ratings": "^1.0.1", "nativescript-socketio": "^3.3.1", "nativescript-store-update": "^1.0.2", "nativescript-theme-core": "^2.0.20", "nativescript-webview-interface": "^1.4.3", "reflect-metadata": "~0.1.13", "rxjs": "^6.5.3", "tns-core-modules": "^6.1.1", "utf8": "^3.0.0", "zone.js": "^0.10.2" }, "devDependencies": { "@angular/cli": "^8.3.4", "@angular/compiler-cli": "~8.2.6", "@nativescript/schematics": "~0.7.1", "@ngtools/webpack": "~8.3.4", "@types/lodash": "^4.14.138", "@types/node": "^12.7.5", "jasmine": "^3.4.0", "nativescript-dev-webpack": "^1.2.0", "tns-platform-declarations": "6.1.1", "node-sass": "4.13.0", "typescript": "~3.5.3" }
Please, tell us how to recreate the issue in as much detail as possible.
Describe the steps to reproduce it. When trying to set cookies in app.module.ts, no cookies are transmitted and the options for cookies is ignored:
SocketIOModule.forRoot(<url_value>, { debug: true, cookies: ["<name>=<value>; Domain=<domain_value>; Path=/; Expires=<expiration_time>"], forceNew: true, forceWebsockets: true, secure: true })
Is there any code involved?
See above.
The issue is that the
interface IOOptions
defined in angular/index.d.ts specifies the key as 'cookies' whereas socketio.ios.ts and socketio.android.ts look for key 'cookie'.Easy fix. Sending a PR.