├── .gitignore ├── src ├── types.ts ├── cli.ts ├── suffix-rules.ts ├── index.ts └── exceptions.ts ├── .prettierrc.js ├── types.flow.js ├── index.html ├── tsconfig.json ├── .github └── workflows │ └── npm-publish.yml ├── package.json ├── README.md └── tests └── test.ts /.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | lib 3 | .vercel 4 | -------------------------------------------------------------------------------- /src/types.ts: -------------------------------------------------------------------------------- 1 | export enum Preposition { 2 | I = 'i', 3 | PÅ = 'på', 4 | } 5 | -------------------------------------------------------------------------------- /.prettierrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | semi: false, 3 | singleQuote: true, 4 | trailingComma: 'all' 5 | } 6 | -------------------------------------------------------------------------------- /types.flow.js: -------------------------------------------------------------------------------- 1 | // @flow 2 | declare module 'preposisjon' { 3 | declare module.exports: (place: string) => 'i' | 'på' 4 | } 5 | -------------------------------------------------------------------------------- /index.html: -------------------------------------------------------------------------------- 1 | 2 |
3 |curl https://preposisjon.no/api?place=voss
9 |
10 |