Files
pastebin/App.js
T
2021-03-09 18:12:30 -05:00

32 lines
635 B
JavaScript

import Note from './Note.js';
function App(){
return {
view: function(vnode){
const {bin} = vnode.attrs;
return m('.app', [
m('.top', [
m('.top-left', [
m('button', {key: 'button'}, 'New Note...'),
m('input.search', {key: 'search'}, {value: ''}),
m('select.sorting', {key: 'sorting'}, [
m('option', 'Newest -> Oldest'),
m('option', 'Oldest -> Newest')
])
]),
m('.top-right', [
m('.bin-id', bin.id),
m('button', 'New Bin...')
])
]),
m('.main', [
m('.notes', notes.map(note =>
m(Note, {note})
))
])
]);
}
};
}
export default App;