Browse Source

Stop using Babel with streaming server (#3950)

pull/4/head
Yamagishi Kazutoshi 4 years ago
committed by Eugen Rochko
parent
commit
285038972b
3 changed files with 12 additions and 27 deletions
  1. +1
    -1
      package.json
  2. +0
    -15
      streaming/.babelrc
  3. +11
    -11
      streaming/index.js

+ 1
- 1
package.json View File

@ -6,7 +6,7 @@
"build:development": "cross-env RAILS_ENV=development ./bin/webpack",
"build:production": "cross-env RAILS_ENV=production ./bin/webpack",
"manage:translations": "node ./config/webpack/translationRunner.js",
"start": "rimraf ./tmp/streaming && babel ./streaming/index.js --out-dir ./tmp && node ./tmp/streaming/index.js",
"start": "node ./streaming/index.js",
"storybook": "cross-env NODE_ENV=test start-storybook -s ./public -p 9001 -c storybook",
"test": "npm run test:lint && npm run test:mocha",
"test:lint": "eslint -c .eslintrc.yml --ext=js app/javascript/ config/webpack/ spec/javascript/ storybook/ streaming/",

+ 0
- 15
streaming/.babelrc View File

@ -1,15 +0,0 @@
{
"presets": [
[
"env",
{
"targets": {
"node": "current"
}
}
]
],
"plugins": [
"transform-object-rest-spread"
]
}

+ 11
- 11
streaming/index.js View File

@ -1,14 +1,14 @@
import os from 'os';
import throng from 'throng';
import dotenv from 'dotenv';
import express from 'express';
import http from 'http';
import redis from 'redis';
import pg from 'pg';
import log from 'npmlog';
import url from 'url';
import WebSocket from 'uws';
import uuid from 'uuid';
const os = require('os');
const throng = require('throng');
const dotenv = require('dotenv');
const express = require('express');
const http = require('http');
const redis = require('redis');
const pg = require('pg');
const log = require('npmlog');
const url = require('url');
const WebSocket = require('uws');
const uuid = require('uuid');
const env = process.env.NODE_ENV || 'development';

Loading…
Cancel
Save