Skip to content

Instantly share code, notes, and snippets.

View andersevenrud's full-sized avatar
🤘
w^w^^w^w

Anders Evenrud andersevenrud

🤘
w^w^^w^w
View GitHub Profile
@andersevenrud
andersevenrud / index.js
Last active April 1, 2019 19:41
Simple OS.js Application w/Server API
//
// Just a standard OS.js application
//
// The "index.js" file.
//
import osjs from 'osjs';
import {name as applicationName} from './metadata.json';
const register = (core, args, options, metadata) => {
const proc = core.make('osjs/application', {args, options, metadata});
import './index.scss';
import osjs from 'osjs';
import {name as applicationName} from './metadata.json';
import {h, app} from 'hyperapp';
import {Box, BoxContainer, Button, Toolbar, TextField, SelectField} from '@osjs/gui';
///////////////////////////////////////////////////////
// Custom GUI Elements
///////////////////////////////////////////////////////
@andersevenrud
andersevenrud / README.md
Created February 2, 2019 18:56
Adding custom icon to OS.js v3 package

In your package

  1. Install webpack plugin to copy files npm install copy-webpack-plugin
  2. Place your icon.png in the directory
  3. Update webpack config -- see file below
  4. Update package metadata --- see file below
  5. Run npm run build

In your installation

@andersevenrud
andersevenrud / README.md
Created January 29, 2019 21:40
DanialdNishazmi Example

Screenshot

/*!
* OS.js - JavaScript Cloud/Web Desktop Platform
*
* Copyright (c) 2011-2019, Anders Evenrud <[email protected]>
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright notice, this
@andersevenrud
andersevenrud / index.js
Last active April 21, 2022 21:49
OS.js v3 - Basic Iframe Example
import './index.scss';
import osjs from 'osjs';
import {name as applicationName} from './metadata.json';
// Our launcher
const register = (core, args, options, metadata) => {
// Create a new Application instance
const proc = core.make('osjs/application', {args, options, metadata});
// Create a new Window instance
@andersevenrud
andersevenrud / TODO.md
Last active January 5, 2019 23:37
OS.js v3 TODO list

OS.js v3 has been released

This is the "general" list of tasks for OS.js v3 development. I'm just adding things here as I go or things pop into mind. So if you see anything interesting and you want to pitch in, that'd be much appreciated.

See the following repositories for issues/todos that are not included here:

import React from 'react';
import ReactDOM from 'react-dom';
//
// Your component(s).
//
class MainWindowComponent extends React.Component {
constructor(props) {
super(props);
@andersevenrud
andersevenrud / index.js
Created June 20, 2018 16:57
OS.js v3 w/React and bi-directional events via bus
import React from 'react';
import ReactDOM from 'react-dom';
//
// Your component(s).
//
class MainWindowComponent extends React.Component {
constructor(props) {
super(props);
@andersevenrud
andersevenrud / README.md
Last active March 3, 2018 16:24
OS.js v3 Application Template

OS.js v3 Application Template

This is a WIP bare-bones template for OS.js v3 apps.

Place it in src/packages/MyApplication and the build system will automatically recognice your package.

Then in console OSjs.run('MyApplication')

NOW AVAILABLE AS A PACKAGE: https://github.com/os-js/osjs-example-package