mirror of
https://github.com/prowler-cloud/prowler.git
synced 2026-10-09 21:14:22 +00:00
feat: render findings first iteration
This commit is contained in:
@@ -1,5 +1,17 @@
|
||||
import { MetaDataProps } from "@/types";
|
||||
|
||||
// Helper function to create dictionaries by type
|
||||
export const createDict = (
|
||||
type: string,
|
||||
data: any,
|
||||
includedField: string = "included",
|
||||
) =>
|
||||
Object.fromEntries(
|
||||
data[includedField]
|
||||
.filter((item: { type: string }) => item.type === type)
|
||||
.map((item: { id: string }) => [item.id, item]),
|
||||
);
|
||||
|
||||
export const parseStringify = (value: any) => JSON.parse(JSON.stringify(value));
|
||||
|
||||
export const convertFileToUrl = (file: File) => URL.createObjectURL(file);
|
||||
+1
-1
@@ -1,2 +1,2 @@
|
||||
export * from "./custom";
|
||||
export * from "./helper";
|
||||
export * from "./utils";
|
||||
|
||||
Reference in New Issue
Block a user