diff --git a/.github/ISSUE_TEMPLATE/BugReport.yaml b/.github/ISSUE_TEMPLATE/BugReport.yaml index 4b6da7871..6a732a9d8 100644 --- a/.github/ISSUE_TEMPLATE/BugReport.yaml +++ b/.github/ISSUE_TEMPLATE/BugReport.yaml @@ -23,7 +23,7 @@ body: - type: textarea attributes: label: .bru file to reproduce the bug - description: Attach your .bru file here that can reqroduce the problem. + description: Attach your .bru file here that can reproduce the problem. validations: required: false - type: textarea diff --git a/packages/bruno-app/src/components/RequestPane/QueryEditor/index.js b/packages/bruno-app/src/components/RequestPane/QueryEditor/index.js index 3d93aae8d..891e2d85a 100644 --- a/packages/bruno-app/src/components/RequestPane/QueryEditor/index.js +++ b/packages/bruno-app/src/components/RequestPane/QueryEditor/index.js @@ -109,7 +109,7 @@ export default class QueryEditor extends React.Component { this.props.onPrettifyQuery(); } }, - /* Shift-Ctrl-P is hard coded in Firefox for private browsing so adding an alternative to Pretiffy */ + /* Shift-Ctrl-P is hard coded in Firefox for private browsing so adding an alternative to Prettify */ 'Shift-Ctrl-F': () => { if (this.props.onPrettifyQuery) { this.props.onPrettifyQuery(); diff --git a/packages/bruno-app/src/components/Sidebar/Collections/Collection/CloneCollection/index.js b/packages/bruno-app/src/components/Sidebar/Collections/Collection/CloneCollection/index.js index 41d3e5ff2..7b34deea4 100644 --- a/packages/bruno-app/src/components/Sidebar/Collections/Collection/CloneCollection/index.js +++ b/packages/bruno-app/src/components/Sidebar/Collections/Collection/CloneCollection/index.js @@ -51,7 +51,7 @@ const CloneCollection = ({ onClose, collection }) => { const browse = () => { dispatch(browseDirectory()) .then((dirPath) => { - // When the user closes the diolog without selecting anything dirPath will be false + // When the user closes the dialog without selecting anything dirPath will be false if (typeof dirPath === 'string') { formik.setFieldValue('collectionLocation', dirPath); } diff --git a/packages/bruno-app/src/components/Sidebar/Collections/Collection/CollectionItem/index.js b/packages/bruno-app/src/components/Sidebar/Collections/Collection/CollectionItem/index.js index 09b9552b5..4191e8777 100644 --- a/packages/bruno-app/src/components/Sidebar/Collections/Collection/CollectionItem/index.js +++ b/packages/bruno-app/src/components/Sidebar/Collections/Collection/CollectionItem/index.js @@ -39,7 +39,7 @@ const CollectionItem = ({ item, collection, searchText }) => { const [newRequestModalOpen, setNewRequestModalOpen] = useState(false); const [newFolderModalOpen, setNewFolderModalOpen] = useState(false); const [runCollectionModalOpen, setRunCollectionModalOpen] = useState(false); - const [itemIsCollapsed, setItemisCollapsed] = useState(item.collapsed); + const [itemIsCollapsed, setItemIsCollapsed] = useState(item.collapsed); const [{ isDragging }, drag] = useDrag({ type: `COLLECTION_ITEM_${collection.uid}`, @@ -66,9 +66,9 @@ const CollectionItem = ({ item, collection, searchText }) => { useEffect(() => { if (searchText && searchText.length) { - setItemisCollapsed(false); + setItemIsCollapsed(false); } else { - setItemisCollapsed(item.collapsed); + setItemIsCollapsed(item.collapsed); } }, [searchText, item]); diff --git a/packages/bruno-app/src/components/Sidebar/CreateCollection/index.js b/packages/bruno-app/src/components/Sidebar/CreateCollection/index.js index 6f05207d2..fd2bc84e0 100644 --- a/packages/bruno-app/src/components/Sidebar/CreateCollection/index.js +++ b/packages/bruno-app/src/components/Sidebar/CreateCollection/index.js @@ -44,7 +44,7 @@ const CreateCollection = ({ onClose }) => { const browse = () => { dispatch(browseDirectory()) .then((dirPath) => { - // When the user closes the diolog without selecting anything dirPath will be false + // When the user closes the dialog without selecting anything dirPath will be false if (typeof dirPath === 'string') { formik.setFieldValue('collectionLocation', dirPath); } diff --git a/packages/bruno-app/src/components/Sidebar/GoldenEdition/index.js b/packages/bruno-app/src/components/Sidebar/GoldenEdition/index.js index 4335bc235..b38ece921 100644 --- a/packages/bruno-app/src/components/Sidebar/GoldenEdition/index.js +++ b/packages/bruno-app/src/components/Sidebar/GoldenEdition/index.js @@ -85,7 +85,7 @@ const GoldenEdition = ({ onClose }) => { }); }; - const goldenEditonIndividuals = [ + const goldenEditionIndividuals = [ 'Inbuilt Bru File Explorer', 'Visual Git (Like Gitlens for Vscode)', 'GRPC, Websocket, SocketIO, MQTT', @@ -97,7 +97,7 @@ const GoldenEdition = ({ onClose }) => { 'Custom Themes' ]; - const goldenEditonOrganizations = [ + const goldenEditionOrganizations = [ 'Centralized License Management', 'Integration with Secret Managers', 'Private Collection Registry', @@ -179,7 +179,7 @@ const GoldenEdition = ({ onClose }) => { {pricingOption === 'individuals' ? ( <> - {goldenEditonIndividuals.map((item, index) => ( + {goldenEditionIndividuals.map((item, index) => (
  • {item} @@ -192,7 +192,7 @@ const GoldenEdition = ({ onClose }) => { Everything in the Individual Plan
  • - {goldenEditonOrganizations.map((item, index) => ( + {goldenEditionOrganizations.map((item, index) => (
  • {item} diff --git a/packages/bruno-app/src/providers/ReduxStore/slices/collections/actions.js b/packages/bruno-app/src/providers/ReduxStore/slices/collections/actions.js index 75c6f2cb9..c9cfadcb0 100644 --- a/packages/bruno-app/src/providers/ReduxStore/slices/collections/actions.js +++ b/packages/bruno-app/src/providers/ReduxStore/slices/collections/actions.js @@ -887,7 +887,7 @@ export const copyEnvironment = (name, baseEnvUid, collectionUid) => (dispatch, g const baseEnv = findEnvironmentInCollection(collection, baseEnvUid); if (!collection) { - return reject(new Error('Environmnent not found')); + return reject(new Error('Environment not found')); } ipcRenderer @@ -1096,7 +1096,7 @@ export const createCollection = (collectionName, collectionFolderName, collectio .catch(reject); }); }; -export const cloneCollection = (collectionName, collectionFolderName, collectionLocation, perviousPath) => () => { +export const cloneCollection = (collectionName, collectionFolderName, collectionLocation, previousPath) => () => { const { ipcRenderer } = window; return ipcRenderer.invoke( @@ -1104,7 +1104,7 @@ export const cloneCollection = (collectionName, collectionFolderName, collection collectionName, collectionFolderName, collectionLocation, - perviousPath + previousPath ); }; export const openCollection = () => () => { diff --git a/packages/bruno-app/src/utils/collections/index.js b/packages/bruno-app/src/utils/collections/index.js index cd925054d..8e431d928 100644 --- a/packages/bruno-app/src/utils/collections/index.js +++ b/packages/bruno-app/src/utils/collections/index.js @@ -21,8 +21,8 @@ const replaceTabsWithSpaces = (str, numSpaces = 2) => { }; export const addDepth = (items = []) => { - const depth = (itms, initialDepth) => { - each(itms, (i) => { + const depth = (items, initialDepth) => { + each(items, (i) => { i.depth = initialDepth; if (i.items && i.items.length) { @@ -65,8 +65,8 @@ export const sortItems = (collection) => { export const flattenItems = (items = []) => { const flattenedItems = []; - const flatten = (itms, flattened) => { - each(itms, (i) => { + const flatten = (items, flattened) => { + each(items, (i) => { flattened.push(i); if (i.items && i.items.length) { diff --git a/packages/bruno-app/src/utils/importers/openapi-collection.js b/packages/bruno-app/src/utils/importers/openapi-collection.js index 01407878a..1d69543ea 100644 --- a/packages/bruno-app/src/utils/importers/openapi-collection.js +++ b/packages/bruno-app/src/utils/importers/openapi-collection.js @@ -31,7 +31,7 @@ const readFile = (files) => { }; const ensureUrl = (url) => { - // emoving multiple slashes after the protocol if it exists, or after the beginning of the string otherwise + // removing multiple slashes after the protocol if it exists, or after the beginning of the string otherwise return url.replace(/([^:])\/{2,}/g, '$1/'); }; diff --git a/packages/bruno-cli/src/commands/run.js b/packages/bruno-cli/src/commands/run.js index 58b3cdf80..34c5e6548 100644 --- a/packages/bruno-cli/src/commands/run.js +++ b/packages/bruno-cli/src/commands/run.js @@ -220,7 +220,7 @@ const builder = async (yargs) => { type: 'string' }) .option('sandbox', { - describe: 'Javscript sandbox to use; available sandboxes are "developer" (default) or "safe"', + describe: 'Javascript sandbox to use; available sandboxes are "developer" (default) or "safe"', default: 'developer', type: 'string' }) @@ -541,7 +541,7 @@ const handler = async function (argv) { nJumps++; if (nJumps > 10000) { console.error(chalk.red(`Too many jumps, possible infinite loop`)); - process.exit(constants.EXIT_STATUS.ERROR_INFINTE_LOOP); + process.exit(constants.EXIT_STATUS.ERROR_INFINITE_LOOP); } if (nextRequestName === null) { break; diff --git a/packages/bruno-cli/src/constants.js b/packages/bruno-cli/src/constants.js index 6d0f877d7..96d7936ae 100644 --- a/packages/bruno-cli/src/constants.js +++ b/packages/bruno-cli/src/constants.js @@ -10,7 +10,7 @@ const EXIT_STATUS = { // The specified output dir does not exist ERROR_MISSING_OUTPUT_DIR: 2, // request chain caused an endless loop - ERROR_INFINTE_LOOP: 3, + ERROR_INFINITE_LOOP: 3, // bru was called outside of a collection root ERROR_NOT_IN_COLLECTION: 4, // The specified file was not found diff --git a/packages/bruno-common/src/interpolate/index.spec.ts b/packages/bruno-common/src/interpolate/index.spec.ts index adfdf54cd..9dc76b7f1 100644 --- a/packages/bruno-common/src/interpolate/index.spec.ts +++ b/packages/bruno-common/src/interpolate/index.spec.ts @@ -297,46 +297,46 @@ describe('interpolate - recursive', () => { expect(result).toBe('{{recursion3}}'); }); - it('should replace repetead placeholders with 1 level of recursion with values from the object', () => { - const inputString = '{{repetead}}'; + it('should replace repeated placeholders with 1 level of recursion with values from the object', () => { + const inputString = '{{repeated}}'; const inputObject = { - repetead: '{{repetead2}} {{repetead2}}', - repetead2: 'repetead2' + repeated: '{{repeated2}} {{repeated2}}', + repeated2: 'repeated2' }; const result = interpolate(inputString, inputObject); - expect(result).toBe(new Array(2).fill('repetead2').join(' ')); + expect(result).toBe(new Array(2).fill('repeated2').join(' ')); }); - it('should replace repetead placeholders with 2 level of recursion with values from the object', () => { - const inputString = '{{repetead}}'; + it('should replace repeated placeholders with 2 level of recursion with values from the object', () => { + const inputString = '{{repeated}}'; const inputObject = { - repetead: '{{repetead2}} {{repetead2}}', - repetead2: '{{repetead3}} {{repetead3}} {{repetead3}}', - repetead3: 'repetead3' + repeated: '{{repeated2}} {{repeated2}}', + repeated2: '{{repeated3}} {{repeated3}} {{repeated3}}', + repeated3: 'repeated3' }; const result = interpolate(inputString, inputObject); - expect(result).toBe(new Array(6).fill('repetead3').join(' ')); + expect(result).toBe(new Array(6).fill('repeated3').join(' ')); }); - it('should replace repetead placeholders with 3 level of recursion with values from the object', () => { - const inputString = '{{repetead}}'; + it('should replace repeated placeholders with 3 level of recursion with values from the object', () => { + const inputString = '{{repeated}}'; const inputObject = { - repetead: '{{repetead2}} {{repetead2}}', - repetead2: '{{repetead3}} {{repetead3}} {{repetead3}}', - repetead3: '{{repetead4}} {{repetead4}} {{repetead4}} {{repetead4}}', - repetead4: 'repetead4' + repeated: '{{repeated2}} {{repeated2}}', + repeated2: '{{repeated3}} {{repeated3}} {{repeated3}}', + repeated3: '{{repeated4}} {{repeated4}} {{repeated4}} {{repeated4}}', + repeated4: 'repeated4' }; const result = interpolate(inputString, inputObject); - expect(result).toBe(new Array(24).fill('repetead4').join(' ')); + expect(result).toBe(new Array(24).fill('repeated4').join(' ')); }); - it('should replace mutiple interdependent variables in the same input string', () => { + it('should replace multiple interdependent variables in the same input string', () => { const inputString = `{ "x": "{{v2}} {{v1}}" }`; diff --git a/packages/bruno-electron/src/cache/requestUids.js b/packages/bruno-electron/src/cache/requestUids.js index 55f7fc291..c6c3bfe7c 100644 --- a/packages/bruno-electron/src/cache/requestUids.js +++ b/packages/bruno-electron/src/cache/requestUids.js @@ -6,7 +6,7 @@ * In the past, we used to generate unique ids based on the * pathname of the request, but we faced problems when implementing * functionality where the user can move the request to a different - * location. In that case, the uid would change, and the we would + * location. In that case, the uid would change, and we would * lose the request's draft state if the user has made some changes */ diff --git a/packages/bruno-electron/src/ipc/collection.js b/packages/bruno-electron/src/ipc/collection.js index 30a891015..9d7c87e36 100644 --- a/packages/bruno-electron/src/ipc/collection.js +++ b/packages/bruno-electron/src/ipc/collection.js @@ -126,7 +126,7 @@ const registerRendererEventHandlers = (mainWindow, watcher, lastOpenedCollection // write the bruno.json to new dir await writeFile(path.join(dirPath, 'bruno.json'), cont); - // Now copy all the files with extension name .bru along with there dir + // Now copy all the files with extension name .bru along with the dir const files = searchForBruFiles(previousPath); for (const sourceFilePath of files) { diff --git a/packages/bruno-electron/src/store/bruno-config.js b/packages/bruno-electron/src/store/bruno-config.js index a092e9357..8942dd833 100644 --- a/packages/bruno-electron/src/store/bruno-config.js +++ b/packages/bruno-electron/src/store/bruno-config.js @@ -4,7 +4,7 @@ const config = {}; -// collectionUid is a hash based on the collection path) +// collectionUid is a hash based on the collection path const getBrunoConfig = (collectionUid) => { return config[collectionUid] || {}; }; diff --git a/packages/bruno-electron/src/store/process-env.js b/packages/bruno-electron/src/store/process-env.js index 578d8df71..084187d2d 100644 --- a/packages/bruno-electron/src/store/process-env.js +++ b/packages/bruno-electron/src/store/process-env.js @@ -11,7 +11,7 @@ const dotEnvVars = {}; -// collectionUid is a hash based on the collection path) +// collectionUid is a hash based on the collection path const getProcessEnvVars = (collectionUid) => { // if there are no .env vars for this collection, return the process.env if (!dotEnvVars[collectionUid]) { diff --git a/packages/bruno-electron/src/utils/collection.js b/packages/bruno-electron/src/utils/collection.js index 5ec40a680..99036020f 100644 --- a/packages/bruno-electron/src/utils/collection.js +++ b/packages/bruno-electron/src/utils/collection.js @@ -4,8 +4,8 @@ const find = require('lodash/find'); const flattenItems = (items = []) => { const flattenedItems = []; - const flatten = (itms, flattened) => { - each(itms, (i) => { + const flatten = (items, flattened) => { + each(items, (i) => { flattened.push(i); if (i.items && i.items.length) { diff --git a/packages/bruno-electron/src/utils/common.js b/packages/bruno-electron/src/utils/common.js index 1962ac260..57ac3109d 100644 --- a/packages/bruno-electron/src/utils/common.js +++ b/packages/bruno-electron/src/utils/common.js @@ -87,7 +87,7 @@ const flattenDataForDotNotation = (data) => { /** * @param {Array.} params The request body Array - * @returns {object} Returns an obj with repeating key as a array of values + * @returns {object} Returns an obj with repeating key as an array of values * {item: 2, item: 3, item1: 4} becomes {item: [2,3], item1: 4} */ const buildFormUrlEncodedPayload = (params) => { diff --git a/packages/bruno-lang/v2/src/jsonToBru.js b/packages/bruno-lang/v2/src/jsonToBru.js index 8d3a5fdee..89cb1fd9f 100644 --- a/packages/bruno-lang/v2/src/jsonToBru.js +++ b/packages/bruno-lang/v2/src/jsonToBru.js @@ -424,4 +424,4 @@ ${indentString(docs)} module.exports = jsonToBru; -// alternative to writing the below code to avoif undefined +// alternative to writing the below code to avoid undefined