Skip to content

Commit

Permalink
lint
Browse files Browse the repository at this point in the history
  • Loading branch information
goastler committed Apr 5, 2024
1 parent 048973f commit ac2a117
Show file tree
Hide file tree
Showing 5 changed files with 65 additions and 0 deletions.
13 changes: 13 additions & 0 deletions packages/configure/src/example.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,16 @@
// Copyright 2021-2024 Prosopo (UK) Ltd.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
import { ConfigSchema } from './tests/config.js'
import { loadConfig } from './index.js'

Expand Down
13 changes: 13 additions & 0 deletions packages/configure/src/index.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,16 @@
// Copyright 2021-2024 Prosopo (UK) Ltd.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
/**
* Loading from json/js/ts has been disabled for now on the basis that it causes issues with loading config in docker/flux. Native env var support makes it super easy to load config from env vars, so this is the recommended approach atm. Unfortunately, this means no dynamic config via js/ts, and no complex config types via js/ts. This is a tradeoff for compatibility. See https://github.com/prosopo/captcha/pull/1136 for reasoning.
*
Expand Down
13 changes: 13 additions & 0 deletions packages/configure/src/tests/config.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,16 @@
// Copyright 2021-2024 Prosopo (UK) Ltd.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
import { z } from 'zod'

export const ConfigSchema = z.object({
Expand Down
13 changes: 13 additions & 0 deletions packages/configure/src/tests/example.config.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,16 @@
// Copyright 2021-2024 Prosopo (UK) Ltd.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
'use strict'
Object.defineProperty(exports, '__esModule', { value: true })
function buildConfig() {
Expand Down
13 changes: 13 additions & 0 deletions packages/configure/src/tests/example.config.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,16 @@
// Copyright 2021-2024 Prosopo (UK) Ltd.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
import { Config } from './config.js'

export default function buildConfig(): Config {
Expand Down

0 comments on commit ac2a117

Please sign in to comment.