小编YaS*_*ary的帖子

网络响应超时错误(create-react-native-app)(expo)

我试图在android中的expo应用程序上运行create-react-native-app.

首先,我通过编写命令创建了项目

create-react-native-app test

然后我执行了

npm开始

然后从expo app扫描qr代码.

但扫描QR码后,我收到以下错误:

Uncaught Error: Java.net,sockettimeoutException: failed to connect to after 10000ms
Run Code Online (Sandbox Code Playgroud)

在此输入图像描述

Github问题:

https://github.com/react-community/create-react-native-app/issues/144#issuecomment-296631692

react-native react-native-android expo create-react-native-app

38
推荐指数
6
解决办法
2万
查看次数

错误:您的要求无法解析为可安装的软件包集.(在服务器上)

我正在为我的项目使用laravel 5.3.现在我将它设置为服务器.

这样做时出现了问题.而且我遇到了这个错误点.

我跑的时候

作曲家安装--no-dev

命令跟随错误发生:

 Problem 1
    - Installation request for fgrosse/phpasn1 1.5.2 -> satisfiable by fgrosse/phpasn1[1.5.2].
    - fgrosse/phpasn1 1.5.2 requires ext-gmp * -> the requested PHP extension gmp is missing from your system.
  Problem 2
    - Installation request for mdanter/ecc v0.4.2 -> satisfiable by mdanter/ecc[v0.4.2].
    - mdanter/ecc v0.4.2 requires ext-gmp * -> the requested PHP extension gmp is missing from your system.
  Problem 3
    - Installation request for pusher/pusher-php-server 2.6.3 -> satisfiable by pusher/pusher-php-server[2.6.3].
    - pusher/pusher-php-server 2.6.3 requires …
Run Code Online (Sandbox Code Playgroud)

laravel composer-php laravel-5.3

16
推荐指数
2
解决办法
3万
查看次数

vagrant homestead无法访问主机(laravel 5.2)

当我转到我的主机ao.dev:8000或ao.dev时,显示"无法访问此站点,ao.dev拒绝连接".

我的yaml文件:

在此输入图像描述

我也是我的观点文件:

我检查过:

在此输入图像描述

我通过访问Homestead目录运行vagrant up命令.

另见:https://stackoverflow.com/questions/38801375/vagrant-up-not-forwarding-all-portshomesteadlaravel-5-2windows-10

php vagrant laravel homestead laravel-5.2

12
推荐指数
1
解决办法
2352
查看次数

http:// localhost:8000/broadcasting/auth 404(未找到)

我想让我的应用程序应用程序连接到私人频道上的推送器.

但是我收到以下错误:

pusher.js?b3eb:593 POST http:// localhost:8000/broadcasting/auth 404(Not Found)

可能是错误的原因以及如何解决它.

laravel pusher laravel-5.3 vuejs2 laravel-echo

12
推荐指数
4
解决办法
1万
查看次数

使用自定义标签与StackNavigator?

我有用户列表,每个用户在列表中都有自己的显示图像.

我正在尝试的是每当用户按下显示图像时,通过stackNavigation重定向到他/她的个人资料.

CustomTabView:

    const CustomTabView = ({ router, navigation }) => {
  const { routes, index } = navigation.state;

  const ActiveScreen = router.getComponentForState(navigation.state);

  const routeNav = addNavigationHelpers({
    ...navigation,
    state: routes[index],
  });
  const routeOptions = router.getScreenOptions(routeNav, 'tabBar');
  return (
    <View style={styles.container}>
      <CustomTabBar
        navigation={navigation}
        activeRouteName={routes[index].routeName}
        icon={routeOptions.tabBarIcon}
      />
      <ActiveScreen
        navigation={addNavigationHelpers({
          ...navigation,
          state: routes[index]
        })}
      />
    </View>
  );
}; 
Run Code Online (Sandbox Code Playgroud)

StackNavigator: // goToProfile.js //也试过放在index.anndroid.js但没找到出口的方法

const goToProfile = StackNavigator({
  Profile: {
    screen: Profile,
    navigationOptions: ({ navigation }) => ({
      title: `${navigation.state.params.person.name.first} ${navigation.state.params.person.name.last}`
    })
  },
})
Run Code Online (Sandbox Code Playgroud)

自定义标签: …

reactjs react-native react-native-android react-navigation

11
推荐指数
1
解决办法
520
查看次数

summernote编辑器未开启(laravel 5.2)

我在laravel 5.2中使用summernote js.

在表单中,当用户单击编辑按钮时,summernote编辑器应该为字段打开.实际上它适用于单个字段,但是当我将其应用于多个字段时,它不起作用.

我的看法:

 <form action="{{route('account')}}" id="acc" class="ac" method="post">
  <div class="col-lg-3"><label>Estado</label>
  @foreach($accounts as $account)
  @if($user== $account->user)
  {!! $account->estado !!}



  <textarea  style="display:none;" name="textfield4" id="textfield4"></textarea>


  <div class="col-lg-2 estado " id="estado"></div>
  @endif
  @endforeach



</div>
  <div class="col-lg-4"></div>
</div>
<div class="row">
  <section class="col-lg-3 "><label for="textfield5">I'm Good At:</label>
  @foreach($accounts as $account)
  @if($user== $account->user)
  {!! $account->goodat !!}





   <textarea  style="display:none;" name="textfield5" id="textfield5"></textarea>
  <div class="col-lg-2 col-md-2 es" id="goodat"></div>

  @endif
  @endforeach

<br /><div><button type="button" class="btn btn-info edit">Edit</button>
    <button type="submit" class="btn btn-success" id="btn-send-message" >Save</button>
    <input type="hidden" value="{{Session::token()}}" name="_token">
    </div>


  </form> …
Run Code Online (Sandbox Code Playgroud)

javascript php jquery laravel summernote

6
推荐指数
1
解决办法
897
查看次数

错误:自动叠加加载(bootstrap)(laravel 5.2)

我在laravel 5.2中使用chart.js.当我转到我的页面时,所有图表都会自动加载(但这不应该发生).另外,我没有使用window.load或window.onload函数.

它应该只在点击时打开(这里,点击图片)

jsfiddle链接:https://jsfiddle.net/Lxdhhj7j/

<div class="container-fluid">
  <div id="myNav1" class="overlay">
  <a href="javascript:void(0)" class="closebtn" onclick="closeNav1()">×</a>
  <div class="overlay-content">

<script>
    

    var year1 = ['FIRST','SECOND','THIRD', 'FOURTH' , 'FIFTH'];
    var data_viewer = <?php echo $viewer; ?>;
    var data_viewer1 = <?php echo $viewer1; ?>;
    var data_viewer2 = <?php echo $viewer2; ?>;
    var data_viewer3 = <?php echo $viewer3; ?>;
    var data_viewer4 = <?php echo $viewer4; ?>;
    var data_viewer5 = <?php echo $viewer5; ?>;
    var data_click = <?php echo $click; ?>; …
Run Code Online (Sandbox Code Playgroud)

javascript php jquery twitter-bootstrap chart.js

6
推荐指数
1
解决办法
515
查看次数

将导航参数作为道具发送到其他组件

我正在使用RN v0.46.4,react-navigation和sendbird.

我正在开发一个聊天应用程序.

我想要做的是用两个参数导航用户到Msg屏幕item(包含用户信息)和createdChannel.

它们只通过一次,即每次我导航到Msg不同用户的屏幕时,我都会收到我先按下的相同值.

聊天屏幕

_chat(item){

 // console.log(item);
 const { navigate } = this.props.navigation

  var userIds = [item.id,1];
  sb = new SendBird({appId: APP_ID});
  sb.connect(1, function(user, error) {
         //console.log(user);
      sb.GroupChannel.createChannelWithUserIds(userIds, true, item.firstname, function(createdChannel, error) {
    if (error) {
        console.error(error);
        return;
    }

   //console.log(createdChannel);
   navigate('Msg', { item, createdChannel })

});
Run Code Online (Sandbox Code Playgroud)

此外,当我createdChannel进入控制台时_chat function,它会按预期提供roght信息.

但是当我在Msg屏幕上控制它时,我只收到创建的第一个createdChannel,已在上面说过.

消息屏幕

 super(props);
  console.log(props.navigation.state.routes[1].params.createdChannel);
Run Code Online (Sandbox Code Playgroud)

我的路由器结构:

const CustomTabRouter = TabRouter(
  {

    Chat: {
      screen: ChatStack, 
      path: ""
    }
} …
Run Code Online (Sandbox Code Playgroud)

react-native sendbird react-native-android

6
推荐指数
1
解决办法
1177
查看次数

如何从javascript中的数组中删除单个实例?

我需要找到最大数量,然后将其从数组中删除。(仅限单个实例)

令数组为

a=[91,65,91,88,26]
Run Code Online (Sandbox Code Playgroud)

我正在使用Math.max()找到最大值

k=Math.max(...a)
Run Code Online (Sandbox Code Playgroud)

现在使用filter()

a=a.filter(e => e!=k);
Run Code Online (Sandbox Code Playgroud)

但它过滤了最大数量的实例。

如何解决呢?

javascript arrays ecmascript-6

5
推荐指数
1
解决办法
1881
查看次数

Git错误:![拒绝] master -&gt; master(非快进)

我正在更新我的项目,当尝试将其上传到我的存储库时,出现以下错误:

已经做了

git pull --rebase origin master

  ! [rejected]        master -> master (non-fast-forward)
error: failed to push some refs to 'https://*******/production.git'
hint: Updates were rejected because the tip of your current branch is behind
hint: its remote counterpart. Integrate the remote changes (e.g.
hint: 'git pull ...') before pushing again.
hint: See the 'Note about fast-forwards' in 'git push --help' for details.
Run Code Online (Sandbox Code Playgroud)

我需要更新我的网站,但无法这样做。

编辑 1:

> git status 给出:

正在变基;到 cda02b2 您当前正在将分支 'master' 重新设置为 'cda02b2'。(修复所有冲突:运行“git rebase --continue”)

无需提交,工作目录干净

git github master bitbucket

2
推荐指数
1
解决办法
2万
查看次数

使用 react-native-vector-icons 图标未显示在屏幕 android 上

我正在使用create-react-native-app。我想使用react-native-vector-icons

但它没有在 android 屏幕上显示任何内容(我在 expo 应用程序上查看它)

这是我所做的:

应用程序.js:

       const Courses = TabNavigator({
  ReactCourses: { screen: ReactCourses },
  NativeCourses: { screen: NativeCourses },
}, {
  tabBarOptions: {
    activeTintColor: '#e91e63',
    swipeEnabled: true,
    showIcon:true,
  },
});
Run Code Online (Sandbox Code Playgroud)

ReactCourses.js:

     import Icon from 'react-native-vector-icons/MaterialIcons';
    static navigationOptions = {
    tabBarLabel: 'React Courses',
    tabBarIcon:({ tintColor }) => (
        <Icon
          name={'home'}
          size={26}
          style={[styles.icon, {color: tintColor}]} />
      )

  }
Run Code Online (Sandbox Code Playgroud)

android react-native react-navigation expo create-react-native-app

1
推荐指数
1
解决办法
9327
查看次数

如何在电子邮件模板中显示重叠的多个图像?

我正在尝试用文本连续显示多个个人资料图片。

这是我得到的:

在此输入图像描述

我想要得到什么:

在此输入图像描述

html email html-table html-email email-templates

1
推荐指数
1
解决办法
1682
查看次数