Merged in fix/3697-prettier-configs (pull request #3396)

fix(SW-3691): Setup one prettier config for whole repo

* Setup prettierrc in root and remove other configs


Approved-by: Joakim Jäderberg
Approved-by: Linus Flood
This commit is contained in:
Rasmus Langvad
2026-01-07 12:45:50 +00:00
parent 932413412b
commit d0546926a9
500 changed files with 18367 additions and 18419 deletions

View File

@@ -1,12 +1,12 @@
'use client'
import NextLink from 'next/link'
import { usePathname, useSearchParams } from 'next/navigation'
import { useMemo } from 'react'
"use client"
import NextLink from "next/link"
import { usePathname, useSearchParams } from "next/navigation"
import { useMemo } from "react"
import { linkVariants } from './variants'
import { linkVariants } from "./variants"
import type { LinkProps } from './link'
import { useIntl } from 'react-intl'
import type { LinkProps } from "./link"
import { useIntl } from "react-intl"
export { LinkProps }
@@ -58,8 +58,8 @@ export default function Link({
const newPath = href
if (keepSearchParams && searchParams.size) {
if (newPath.includes('?')) {
const newPathParts = newPath.split('?')
if (newPath.includes("?")) {
const newPathParts = newPath.split("?")
const newSearchParams = new URLSearchParams(newPathParts[1])
searchParams.forEach((v, k) => {
if (!newSearchParams.has(k)) {
@@ -81,12 +81,12 @@ export default function Link({
href: fullUrl,
className: classNames,
title:
props.target === '_blank'
props.target === "_blank"
? intl.formatMessage({
id: 'common.linkOpenInNewTab',
defaultMessage: 'Opens in a new tab/window',
id: "common.linkOpenInNewTab",
defaultMessage: "Opens in a new tab/window",
})
: '',
: "",
}
return isExternal ? (
@@ -112,7 +112,7 @@ export default function Link({
const useCheckIfExternalLink = (url: string) => {
return useMemo(() => {
if (typeof window !== 'undefined' && url?.length) {
if (typeof window !== "undefined" && url?.length) {
try {
const hostName = window.location.hostname
const newURL = new URL(url)