Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding Image to Keystone Document Field (WIP) #1

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 7 additions & 18 deletions keystone.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,28 +6,17 @@ It looks at the default export, and expects a Keystone config object.
You can find all the config options in our docs here: https://keystonejs.com/docs/apis/config
*/

import { config } from '@keystone-6/core';
import {config} from '@keystone-6/core';

// Look in the schema file for how we define our lists, and how users interact with them through graphql or the Admin UI
import { lists } from './schema';
import {lists} from './schema';

// Keystone auth is configured separately - check out the basic auth setup we are importing from our auth file.
import { withAuth, session } from './auth';

export default withAuth(
// Using the config function helps typescript guide you to the available options.
config({
export default // Using the config function helps typescript guide you to the available options.
config({
// the db sets the database provider - we're using sqlite for the fastest startup experience
db: {
provider: 'sqlite',
url: 'file:./keystone.db',
},
// This config allows us to set up features of the Admin UI https://keystonejs.com/docs/apis/config#ui
ui: {
// For our starter, we check that someone has session data before letting them see the Admin UI.
isAccessAllowed: (context) => !!context.session?.data,
provider: 'sqlite',
url: 'file:./keystone.db',
},
lists,
session,
})
);
});
Loading