Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@twreporter/redux

Package Overview
Dependencies
Maintainers
0
Versions
183
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@twreporter/redux - npm Package Compare versions

Comparing version 8.1.0-rc.0 to 8.1.0-rc.1

11

CHANGELOG.md

@@ -6,2 +6,13 @@ # Change Log

# [8.1.0-rc.1](https://github.com/twreporter/twreporter-npm-packages/compare/@twreporter/redux@8.1.0-rc.0...@twreporter/redux@8.1.0-rc.1) (2024-07-09)
### Features
* add jwt for getting full post ([d5d0f16](https://github.com/twreporter/twreporter-npm-packages/commit/d5d0f16ae807882254c318488f97904aef50e18e))
# [8.1.0-rc.0](https://github.com/twreporter/twreporter-npm-packages/compare/@twreporter/redux@8.0.3...@twreporter/redux@8.1.0-rc.0) (2024-07-09)

@@ -8,0 +19,0 @@

18

lib/actions/posts.js

@@ -43,2 +43,3 @@ "use strict";

* @param {string} slug - slug of post
* @param {string} jwt - access_token granted for the user
* @param {number} [timeout=apiConfig.timeout] - request api timeout

@@ -48,3 +49,4 @@ * @return {import('../typedef').Thunk} async action creator

function fetchAFullPost(slug) {
var timeout = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : _apiConfig["default"].timeout;
var jwt = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';
var timeout = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : _apiConfig["default"].timeout;
return function (dispatch, getState) {

@@ -86,3 +88,4 @@ var state = getState();

var url = (0, _url.formURL)(apiOrigin, path, {
full: 'true'
full: 'true',
toggleBookmark: 'true'
});

@@ -96,5 +99,12 @@ // Start to get topics

});
return _axios["default"].get(url, {
var config = {
timeout: timeout
}).then(function (response) {
};
if (jwt) {
config.headers = {
Authorization: "Bearer ".concat(jwt)
};
config.withCredentials = true;
}
return _axios["default"].get(url, config).then(function (response) {
var successAction = {

@@ -101,0 +111,0 @@ type: _actionTypes["default"].selectedPost.read.success,

{
"name": "@twreporter/redux",
"version": "8.1.0-rc.0",
"version": "8.1.0-rc.1",
"description": "redux actions and reducers for twreporter website",

@@ -49,3 +49,3 @@ "repository": "https://github.com/twreporter/twreporter-npm-packages.git",

],
"gitHead": "818d27707d41db85fb9f095ae14fdfd391555550"
"gitHead": "d3003a89e37a0f2ef1fe5e5424b6d6e13a9028db"
}
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc