Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
59 commits
Select commit Hold shift + click to select a range
be88c1a
Update README.md
azcn2503 Aug 10, 2018
d49c9ba
set default style with min-height & word-bread
Sep 4, 2018
8f3c832
Fix bug with small floats and add support for scientific notation
EvertEt Nov 6, 2018
1a4591b
add quotesOnKeys option
kochis Sep 6, 2019
1d4eee7
Add property that hides the array keys
imdanielsp Apr 4, 2020
2459d45
Add Github actions to run tests on CI
usulpro Jul 6, 2020
677a50d
Inline SCSS styles
thomasjm Aug 29, 2020
2892e3f
Bump a bunch of packages
thomasjm Aug 29, 2020
b051983
Rebuild demo
thomasjm Aug 29, 2020
3960567
Put back loaders needed to build the demo
thomasjm Aug 29, 2020
80cbf34
Fix another CopyToClipboard hover
thomasjm Aug 29, 2020
98f029b
Rebuild demo
thomasjm Aug 29, 2020
8dd9409
Fix another window ReferenceError issue
thomasjm Aug 29, 2020
831b37f
Re-indent dev-server/dist/index.html
thomasjm Aug 31, 2020
5f44a4e
Adds support for React 17
uzikilon Oct 29, 2020
8a295cf
Merge pull request #213 from azcn2503/patch-1
mac-s-g Jan 16, 2021
46f0a72
Merge pull request #218 from gfortaine/default-style
mac-s-g Jan 16, 2021
87011cd
Merge pull request #231 from EvertEt/fix/scientific-float
mac-s-g Jan 16, 2021
622bd65
Merge pull request #271 from kochis/remove-quotes-from-keys-option
mac-s-g Jan 16, 2021
5c67e94
Merge pull request #303 from uzikilon/patch-1
mac-s-g Jan 16, 2021
e5330e0
Merge pull request #293 from mac-s-g/feature/setup-ci
mac-s-g Jan 16, 2021
b939ee4
merging-master
ava-macg Jan 16, 2021
3c9bdaa
updating coveralls version, ensuring node_env is test before sending …
ava-macg Jan 16, 2021
9c57b96
updating lint rules to fix tests
ava-macg Jan 17, 2021
b0b8914
went-down-a-rabbit-hole
ava-macg Jan 17, 2021
875a3f4
wrong git user
mac-s-g Jan 17, 2021
937d783
upgraded some dependencies, upgraded docker node image
mac-s-g Jan 17, 2021
e12f320
i think i got it
mac-s-g Jan 17, 2021
e58c4e0
Merge pull request #311 from mac-s-g/thomasjm-inline-styles
mac-s-g Jan 17, 2021
db92bbe
bump version and update demo build
mac-s-g Jan 17, 2021
ef2736c
Merge pull request #312 from mac-s-g/bump-minor-version
mac-s-g Jan 17, 2021
d1ef3a2
remove node dependency
mac-s-g Jan 19, 2021
687c00f
Merge pull request #314 from mac-s-g/node-dependency
mac-s-g Jan 19, 2021
730b65b
upgrading flux to 4.0.1
mac-s-g Jan 19, 2021
23c3d0f
Merge pull request #315 from mac-s-g/update-flux-dependency
mac-s-g Jan 19, 2021
c8cbcdd
remove coverage info from production build
mac-s-g Jan 24, 2021
354dd3a
Merge pull request #318 from mac-s-g/published-coverage
mac-s-g Jan 24, 2021
fa4b769
updating demo build
mac-s-g Jan 25, 2021
74e0da1
Merge pull request #319 from mac-s-g/update-demo-build
mac-s-g Jan 25, 2021
4820be3
demo build was broken...
mac-s-g Jan 25, 2021
91b4c3c
Merge pull request #320 from mac-s-g/update-demo-build
mac-s-g Jan 25, 2021
07ab814
copy literal to clipboard bugfix
mac-s-g Jan 25, 2021
71d5c1d
bump patch version
mac-s-g Jan 25, 2021
4d7d667
remove debugging
mac-s-g Jan 25, 2021
3d1b050
update demo build
mac-s-g Jan 25, 2021
e2ca308
Merge pull request #321 from mac-s-g/copy-to-clipboard-bug
mac-s-g Jan 25, 2021
d386ade
Don't sort keys if the object is an array.
clangen-nw Jun 18, 2019
825e8dc
Merge pull request #322 from elrob/master
mac-s-g Feb 3, 2021
911ced9
bump patch version
mac-s-g Feb 3, 2021
f224c39
Merge pull request #324 from mac-s-g/bump-patch
mac-s-g Feb 3, 2021
3b2e96c
Merge branch 'master' into master
imdanielsp Feb 4, 2021
0ec198e
Add extract missing prop after resolving conflict
imdanielsp Feb 4, 2021
6b50e71
Apply linter rules
imdanielsp Feb 4, 2021
1487e87
Merge pull request #284 from imdanielsp/master
mac-s-g Feb 5, 2021
fe622a2
bump minor version to include displayArrayKey prop
mac-s-g Feb 5, 2021
fd0e6ec
Merge pull request #325 from mac-s-g/bump-minor
mac-s-g Feb 5, 2021
d5f93a9
quotesOnKeys bugfix
mac-s-g Feb 5, 2021
e27fabc
Merge pull request #328 from mac-s-g/bump-minor
mac-s-g Feb 5, 2021
142d026
Merge branch 'master' of github.com-fs:mac-s-g/react-json-view into m…
thanhlm27 Mar 1, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 11 additions & 4 deletions .babelrc
Original file line number Diff line number Diff line change
@@ -1,8 +1,15 @@
{
"presets": ["react-app"],
"plugins": [
'transform-class-properties',
'react-html-attrs',
'transform-function-bind'
"@babel/plugin-syntax-class-properties",
"@babel/plugin-syntax-jsx",
"react-html-attrs"
],
"presets": ["react", "es2015", "stage-0"]
"env": {
"test": {
"plugins": [
"istanbul"
]
}
}
}
2 changes: 1 addition & 1 deletion .coveralls.yml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
service-name: travis-ci
repo_token: vgY2Lq1R7eqlkcmpp4wU32xZI7JskTACs
repo_token: 5tBngUO90HTikmfFGI6ve2w7sVSau3N9K
41 changes: 0 additions & 41 deletions .eslintrc.js

This file was deleted.

20 changes: 20 additions & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"plugins": ["react", "prettier"],
"rules": {
"prettier/prettier": "error",
"import/no-anonymous-default-export": "off",
"egegeg": "off"
},
"parser":"@babel/eslint-parser",
"parserOptions": {
"sourceType": "module",
"ecmaVersion": 6,
"ecmaFeatures": {
"experimentalObjectRestSpread": true
}
},
"env": {
"es6": true,
"node": true
}
}
25 changes: 25 additions & 0 deletions .github/workflows/ci-tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: ci_tests

on:
pull_request:
branches:
- master
push:

jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: actions/setup-node@v1
with:
node-version: 12
- name: Cache node modules
uses: actions/cache@v1
with:
path: node_modules
key: dependencies
- run: npm i
- run: npm run lint
- run: npm run test

2 changes: 1 addition & 1 deletion .nycrc
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"plugins": ["transform-decorators-legacy"],
"require": [
"babel-register",
"@babel/register",
"./test/testHelpers/requireSources.js"
]
}
15 changes: 15 additions & 0 deletions .prettierrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"tabWidth": 4,
"printWidth": 80,
"singleQuote": true,
"trailingComma": "none",
"bracketSpacing": true,
"jsxBracketSameLine": false,
"parser": "babel",
"semi": true,
"requirePragma": false,
"proseWrap": "preserve",
"arrowParens": "avoid",
"eslintIntegration": false,
"endOfLine": "auto"
}
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM node:8.4.0-slim
FROM node:14.15.4-buster-slim
MAINTAINER mac <mac.gainor@gmail.com>

# install the node modules at container build time
Expand Down
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ Name|Type|Default|Description
`collapsed`|`boolean` or `integer`|`false`|When set to `true`, all nodes will be collapsed by default. Use an integer value to collapse at a particular depth.
`collapseStringsAfterLength`|`integer`|`false`|When an integer value is assigned, strings will be cut off at that length. Collapsed strings are followed by an ellipsis. String content can be expanded and collapsed by clicking on the string value.
`shouldCollapse`|`(field)=>{}`|`false`|Callback function to provide control over what objects and arrays should be collapsed by default. An object is passed to the callback containing `name`, `src`, `type` ("array" or "object") and `namespace`.
`groupArraysAfterLength`|`integer`|`100`|When an integer value is assigned, arrays will be displayed in groups by count of the value. Groups are displayed with brakcet notation and can be expanded and collapsed by clickong on the brackets.
`groupArraysAfterLength`|`integer`|`100`|When an integer value is assigned, arrays will be displayed in groups by count of the value. Groups are displayed with bracket notation and can be expanded and collapsed by clicking on the brackets.
`enableClipboard`|`boolean` or `(copy)=>{}`|`true`|When prop is not `false`, the user can copy objects and arrays to clipboard by clicking on the clipboard icon. Copy callbacks are supported.
`displayObjectSize`|`boolean`|`true`|When set to `true`, objects and arrays are labeled with size
`displayDataTypes`|`boolean`|`true`|When set to `true`, data type labels prefix values
Expand All @@ -59,7 +59,9 @@ Name|Type|Default|Description
`onDelete`|`(delete)=>{}`|`false`|When a callback function is passed in, `delete` functionality is enabled. The callback is invoked before deletions are completed. Returning `false` from `onDelete` will prevent the change from being made. [see: onDelete docs](#onedit-onadd-and-ondelete-interaction)
`onSelect`|`(select)=>{}`|`false`|When a function is passed in, clicking a value triggers the `onSelect` method to be called.
`sortKeys`|`boolean`|`false`|set to true to sort object keys
`quotesOnKeys`|`boolean`|`true`|set to false to remove quotes from keys (eg. `"name":` vs. `name:`)
`validationMessage`|`string`|"Validation Error"|Custom message for validation failures to `onEdit`, `onAdd`, or `onDelete` callbacks
`displayArrayKey`|`boolean`|`true`|When set to `true`, the index of the elements prefix values

### Features
* `onEdit`, `onAdd` and `onDelete` props allow users to edit the `src` variable
Expand Down
15 changes: 8 additions & 7 deletions demo/dist/main.js

Large diffs are not rendered by default.

Loading